pinctrl-bcm6362.c 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604
  1. // SPDX-License-Identifier: GPL-2.0+
  2. /*
  3. * Driver for BCM6362 GPIO unit (pinctrl + GPIO)
  4. *
  5. * Copyright (C) 2021 Álvaro Fernández Rojas <[email protected]>
  6. * Copyright (C) 2016 Jonas Gorski <[email protected]>
  7. */
  8. #include <linux/bits.h>
  9. #include <linux/gpio/driver.h>
  10. #include <linux/kernel.h>
  11. #include <linux/of.h>
  12. #include <linux/pinctrl/pinmux.h>
  13. #include <linux/platform_device.h>
  14. #include <linux/regmap.h>
  15. #include "../pinctrl-utils.h"
  16. #include "pinctrl-bcm63xx.h"
  17. #define BCM6362_BANK_GPIOS 32
  18. #define BCM6362_NUM_GPIOS 48
  19. #define BCM6362_NUM_LEDS 24
  20. #define BCM6362_LED_REG 0x10
  21. #define BCM6362_MODE_REG 0x18
  22. #define BCM6362_CTRL_REG 0x1c
  23. #define BCM6362_BASEMODE_REG 0x38
  24. #define BASEMODE_NAND BIT(2)
  25. enum bcm6362_pinctrl_reg {
  26. BCM6362_LEDCTRL,
  27. BCM6362_MODE,
  28. BCM6362_CTRL,
  29. BCM6362_BASEMODE,
  30. };
  31. struct bcm6362_function {
  32. const char *name;
  33. const char * const *groups;
  34. const unsigned num_groups;
  35. enum bcm6362_pinctrl_reg reg;
  36. uint32_t basemode_mask;
  37. };
  38. #define BCM6362_PIN(a, b, mask) \
  39. { \
  40. .number = a, \
  41. .name = b, \
  42. .drv_data = (void *)(mask), \
  43. }
  44. static const struct pinctrl_pin_desc bcm6362_pins[] = {
  45. PINCTRL_PIN(0, "gpio0"),
  46. PINCTRL_PIN(1, "gpio1"),
  47. PINCTRL_PIN(2, "gpio2"),
  48. PINCTRL_PIN(3, "gpio3"),
  49. PINCTRL_PIN(4, "gpio4"),
  50. PINCTRL_PIN(5, "gpio5"),
  51. PINCTRL_PIN(6, "gpio6"),
  52. PINCTRL_PIN(7, "gpio7"),
  53. BCM6362_PIN(8, "gpio8", BASEMODE_NAND),
  54. PINCTRL_PIN(9, "gpio9"),
  55. PINCTRL_PIN(10, "gpio10"),
  56. PINCTRL_PIN(11, "gpio11"),
  57. BCM6362_PIN(12, "gpio12", BASEMODE_NAND),
  58. BCM6362_PIN(13, "gpio13", BASEMODE_NAND),
  59. BCM6362_PIN(14, "gpio14", BASEMODE_NAND),
  60. BCM6362_PIN(15, "gpio15", BASEMODE_NAND),
  61. BCM6362_PIN(16, "gpio16", BASEMODE_NAND),
  62. BCM6362_PIN(17, "gpio17", BASEMODE_NAND),
  63. BCM6362_PIN(18, "gpio18", BASEMODE_NAND),
  64. BCM6362_PIN(19, "gpio19", BASEMODE_NAND),
  65. BCM6362_PIN(20, "gpio20", BASEMODE_NAND),
  66. BCM6362_PIN(21, "gpio21", BASEMODE_NAND),
  67. BCM6362_PIN(22, "gpio22", BASEMODE_NAND),
  68. BCM6362_PIN(23, "gpio23", BASEMODE_NAND),
  69. PINCTRL_PIN(24, "gpio24"),
  70. PINCTRL_PIN(25, "gpio25"),
  71. PINCTRL_PIN(26, "gpio26"),
  72. BCM6362_PIN(27, "gpio27", BASEMODE_NAND),
  73. PINCTRL_PIN(28, "gpio28"),
  74. PINCTRL_PIN(29, "gpio29"),
  75. PINCTRL_PIN(30, "gpio30"),
  76. PINCTRL_PIN(31, "gpio31"),
  77. PINCTRL_PIN(32, "gpio32"),
  78. PINCTRL_PIN(33, "gpio33"),
  79. PINCTRL_PIN(34, "gpio34"),
  80. PINCTRL_PIN(35, "gpio35"),
  81. PINCTRL_PIN(36, "gpio36"),
  82. PINCTRL_PIN(37, "gpio37"),
  83. PINCTRL_PIN(38, "gpio38"),
  84. PINCTRL_PIN(39, "gpio39"),
  85. PINCTRL_PIN(40, "gpio40"),
  86. PINCTRL_PIN(41, "gpio41"),
  87. PINCTRL_PIN(42, "gpio42"),
  88. PINCTRL_PIN(43, "gpio43"),
  89. PINCTRL_PIN(44, "gpio44"),
  90. PINCTRL_PIN(45, "gpio45"),
  91. PINCTRL_PIN(46, "gpio46"),
  92. PINCTRL_PIN(47, "gpio47"),
  93. };
  94. static unsigned gpio0_pins[] = { 0 };
  95. static unsigned gpio1_pins[] = { 1 };
  96. static unsigned gpio2_pins[] = { 2 };
  97. static unsigned gpio3_pins[] = { 3 };
  98. static unsigned gpio4_pins[] = { 4 };
  99. static unsigned gpio5_pins[] = { 5 };
  100. static unsigned gpio6_pins[] = { 6 };
  101. static unsigned gpio7_pins[] = { 7 };
  102. static unsigned gpio8_pins[] = { 8 };
  103. static unsigned gpio9_pins[] = { 9 };
  104. static unsigned gpio10_pins[] = { 10 };
  105. static unsigned gpio11_pins[] = { 11 };
  106. static unsigned gpio12_pins[] = { 12 };
  107. static unsigned gpio13_pins[] = { 13 };
  108. static unsigned gpio14_pins[] = { 14 };
  109. static unsigned gpio15_pins[] = { 15 };
  110. static unsigned gpio16_pins[] = { 16 };
  111. static unsigned gpio17_pins[] = { 17 };
  112. static unsigned gpio18_pins[] = { 18 };
  113. static unsigned gpio19_pins[] = { 19 };
  114. static unsigned gpio20_pins[] = { 20 };
  115. static unsigned gpio21_pins[] = { 21 };
  116. static unsigned gpio22_pins[] = { 22 };
  117. static unsigned gpio23_pins[] = { 23 };
  118. static unsigned gpio24_pins[] = { 24 };
  119. static unsigned gpio25_pins[] = { 25 };
  120. static unsigned gpio26_pins[] = { 26 };
  121. static unsigned gpio27_pins[] = { 27 };
  122. static unsigned gpio28_pins[] = { 28 };
  123. static unsigned gpio29_pins[] = { 29 };
  124. static unsigned gpio30_pins[] = { 30 };
  125. static unsigned gpio31_pins[] = { 31 };
  126. static unsigned gpio32_pins[] = { 32 };
  127. static unsigned gpio33_pins[] = { 33 };
  128. static unsigned gpio34_pins[] = { 34 };
  129. static unsigned gpio35_pins[] = { 35 };
  130. static unsigned gpio36_pins[] = { 36 };
  131. static unsigned gpio37_pins[] = { 37 };
  132. static unsigned gpio38_pins[] = { 38 };
  133. static unsigned gpio39_pins[] = { 39 };
  134. static unsigned gpio40_pins[] = { 40 };
  135. static unsigned gpio41_pins[] = { 41 };
  136. static unsigned gpio42_pins[] = { 42 };
  137. static unsigned gpio43_pins[] = { 43 };
  138. static unsigned gpio44_pins[] = { 44 };
  139. static unsigned gpio45_pins[] = { 45 };
  140. static unsigned gpio46_pins[] = { 46 };
  141. static unsigned gpio47_pins[] = { 47 };
  142. static unsigned nand_grp_pins[] = {
  143. 8, 12, 13, 14, 15, 16, 17,
  144. 18, 19, 20, 21, 22, 23, 27,
  145. };
  146. static struct pingroup bcm6362_groups[] = {
  147. BCM_PIN_GROUP(gpio0),
  148. BCM_PIN_GROUP(gpio1),
  149. BCM_PIN_GROUP(gpio2),
  150. BCM_PIN_GROUP(gpio3),
  151. BCM_PIN_GROUP(gpio4),
  152. BCM_PIN_GROUP(gpio5),
  153. BCM_PIN_GROUP(gpio6),
  154. BCM_PIN_GROUP(gpio7),
  155. BCM_PIN_GROUP(gpio8),
  156. BCM_PIN_GROUP(gpio9),
  157. BCM_PIN_GROUP(gpio10),
  158. BCM_PIN_GROUP(gpio11),
  159. BCM_PIN_GROUP(gpio12),
  160. BCM_PIN_GROUP(gpio13),
  161. BCM_PIN_GROUP(gpio14),
  162. BCM_PIN_GROUP(gpio15),
  163. BCM_PIN_GROUP(gpio16),
  164. BCM_PIN_GROUP(gpio17),
  165. BCM_PIN_GROUP(gpio18),
  166. BCM_PIN_GROUP(gpio19),
  167. BCM_PIN_GROUP(gpio20),
  168. BCM_PIN_GROUP(gpio21),
  169. BCM_PIN_GROUP(gpio22),
  170. BCM_PIN_GROUP(gpio23),
  171. BCM_PIN_GROUP(gpio24),
  172. BCM_PIN_GROUP(gpio25),
  173. BCM_PIN_GROUP(gpio26),
  174. BCM_PIN_GROUP(gpio27),
  175. BCM_PIN_GROUP(gpio28),
  176. BCM_PIN_GROUP(gpio29),
  177. BCM_PIN_GROUP(gpio30),
  178. BCM_PIN_GROUP(gpio31),
  179. BCM_PIN_GROUP(gpio32),
  180. BCM_PIN_GROUP(gpio33),
  181. BCM_PIN_GROUP(gpio34),
  182. BCM_PIN_GROUP(gpio35),
  183. BCM_PIN_GROUP(gpio36),
  184. BCM_PIN_GROUP(gpio37),
  185. BCM_PIN_GROUP(gpio38),
  186. BCM_PIN_GROUP(gpio39),
  187. BCM_PIN_GROUP(gpio40),
  188. BCM_PIN_GROUP(gpio41),
  189. BCM_PIN_GROUP(gpio42),
  190. BCM_PIN_GROUP(gpio43),
  191. BCM_PIN_GROUP(gpio44),
  192. BCM_PIN_GROUP(gpio45),
  193. BCM_PIN_GROUP(gpio46),
  194. BCM_PIN_GROUP(gpio47),
  195. BCM_PIN_GROUP(nand_grp),
  196. };
  197. static const char * const led_groups[] = {
  198. "gpio0",
  199. "gpio1",
  200. "gpio2",
  201. "gpio3",
  202. "gpio4",
  203. "gpio5",
  204. "gpio6",
  205. "gpio7",
  206. "gpio8",
  207. "gpio9",
  208. "gpio10",
  209. "gpio11",
  210. "gpio12",
  211. "gpio13",
  212. "gpio14",
  213. "gpio15",
  214. "gpio16",
  215. "gpio17",
  216. "gpio18",
  217. "gpio19",
  218. "gpio20",
  219. "gpio21",
  220. "gpio22",
  221. "gpio23",
  222. };
  223. static const char * const usb_device_led_groups[] = {
  224. "gpio0",
  225. };
  226. static const char * const sys_irq_groups[] = {
  227. "gpio1",
  228. };
  229. static const char * const serial_led_clk_groups[] = {
  230. "gpio2",
  231. };
  232. static const char * const serial_led_data_groups[] = {
  233. "gpio3",
  234. };
  235. static const char * const robosw_led_data_groups[] = {
  236. "gpio4",
  237. };
  238. static const char * const robosw_led_clk_groups[] = {
  239. "gpio5",
  240. };
  241. static const char * const robosw_led0_groups[] = {
  242. "gpio6",
  243. };
  244. static const char * const robosw_led1_groups[] = {
  245. "gpio7",
  246. };
  247. static const char * const inet_led_groups[] = {
  248. "gpio8",
  249. };
  250. static const char * const spi_cs2_groups[] = {
  251. "gpio9",
  252. };
  253. static const char * const spi_cs3_groups[] = {
  254. "gpio10",
  255. };
  256. static const char * const ntr_pulse_groups[] = {
  257. "gpio11",
  258. };
  259. static const char * const uart1_scts_groups[] = {
  260. "gpio12",
  261. };
  262. static const char * const uart1_srts_groups[] = {
  263. "gpio13",
  264. };
  265. static const char * const uart1_sdin_groups[] = {
  266. "gpio14",
  267. };
  268. static const char * const uart1_sdout_groups[] = {
  269. "gpio15",
  270. };
  271. static const char * const adsl_spi_miso_groups[] = {
  272. "gpio16",
  273. };
  274. static const char * const adsl_spi_mosi_groups[] = {
  275. "gpio17",
  276. };
  277. static const char * const adsl_spi_clk_groups[] = {
  278. "gpio18",
  279. };
  280. static const char * const adsl_spi_cs_groups[] = {
  281. "gpio19",
  282. };
  283. static const char * const ephy0_led_groups[] = {
  284. "gpio20",
  285. };
  286. static const char * const ephy1_led_groups[] = {
  287. "gpio21",
  288. };
  289. static const char * const ephy2_led_groups[] = {
  290. "gpio22",
  291. };
  292. static const char * const ephy3_led_groups[] = {
  293. "gpio23",
  294. };
  295. static const char * const ext_irq0_groups[] = {
  296. "gpio24",
  297. };
  298. static const char * const ext_irq1_groups[] = {
  299. "gpio25",
  300. };
  301. static const char * const ext_irq2_groups[] = {
  302. "gpio26",
  303. };
  304. static const char * const ext_irq3_groups[] = {
  305. "gpio27",
  306. };
  307. static const char * const wifi_groups[] = {
  308. "gpio32",
  309. "gpio33",
  310. "gpio34",
  311. "gpio35",
  312. "gpio36",
  313. "gpio37",
  314. "gpio38",
  315. "gpio39",
  316. "gpio40",
  317. "gpio41",
  318. "gpio42",
  319. "gpio43",
  320. "gpio44",
  321. "gpio45",
  322. "gpio46",
  323. "gpio47",
  324. };
  325. static const char * const nand_groups[] = {
  326. "nand_grp",
  327. };
  328. #define BCM6362_LED_FUN(n) \
  329. { \
  330. .name = #n, \
  331. .groups = n##_groups, \
  332. .num_groups = ARRAY_SIZE(n##_groups), \
  333. .reg = BCM6362_LEDCTRL, \
  334. }
  335. #define BCM6362_MODE_FUN(n) \
  336. { \
  337. .name = #n, \
  338. .groups = n##_groups, \
  339. .num_groups = ARRAY_SIZE(n##_groups), \
  340. .reg = BCM6362_MODE, \
  341. }
  342. #define BCM6362_CTRL_FUN(n) \
  343. { \
  344. .name = #n, \
  345. .groups = n##_groups, \
  346. .num_groups = ARRAY_SIZE(n##_groups), \
  347. .reg = BCM6362_CTRL, \
  348. }
  349. #define BCM6362_BASEMODE_FUN(n, mask) \
  350. { \
  351. .name = #n, \
  352. .groups = n##_groups, \
  353. .num_groups = ARRAY_SIZE(n##_groups), \
  354. .reg = BCM6362_BASEMODE, \
  355. .basemode_mask = (mask), \
  356. }
  357. static const struct bcm6362_function bcm6362_funcs[] = {
  358. BCM6362_LED_FUN(led),
  359. BCM6362_MODE_FUN(usb_device_led),
  360. BCM6362_MODE_FUN(sys_irq),
  361. BCM6362_MODE_FUN(serial_led_clk),
  362. BCM6362_MODE_FUN(serial_led_data),
  363. BCM6362_MODE_FUN(robosw_led_data),
  364. BCM6362_MODE_FUN(robosw_led_clk),
  365. BCM6362_MODE_FUN(robosw_led0),
  366. BCM6362_MODE_FUN(robosw_led1),
  367. BCM6362_MODE_FUN(inet_led),
  368. BCM6362_MODE_FUN(spi_cs2),
  369. BCM6362_MODE_FUN(spi_cs3),
  370. BCM6362_MODE_FUN(ntr_pulse),
  371. BCM6362_MODE_FUN(uart1_scts),
  372. BCM6362_MODE_FUN(uart1_srts),
  373. BCM6362_MODE_FUN(uart1_sdin),
  374. BCM6362_MODE_FUN(uart1_sdout),
  375. BCM6362_MODE_FUN(adsl_spi_miso),
  376. BCM6362_MODE_FUN(adsl_spi_mosi),
  377. BCM6362_MODE_FUN(adsl_spi_clk),
  378. BCM6362_MODE_FUN(adsl_spi_cs),
  379. BCM6362_MODE_FUN(ephy0_led),
  380. BCM6362_MODE_FUN(ephy1_led),
  381. BCM6362_MODE_FUN(ephy2_led),
  382. BCM6362_MODE_FUN(ephy3_led),
  383. BCM6362_MODE_FUN(ext_irq0),
  384. BCM6362_MODE_FUN(ext_irq1),
  385. BCM6362_MODE_FUN(ext_irq2),
  386. BCM6362_MODE_FUN(ext_irq3),
  387. BCM6362_CTRL_FUN(wifi),
  388. BCM6362_BASEMODE_FUN(nand, BASEMODE_NAND),
  389. };
  390. static int bcm6362_pinctrl_get_group_count(struct pinctrl_dev *pctldev)
  391. {
  392. return ARRAY_SIZE(bcm6362_groups);
  393. }
  394. static const char *bcm6362_pinctrl_get_group_name(struct pinctrl_dev *pctldev,
  395. unsigned group)
  396. {
  397. return bcm6362_groups[group].name;
  398. }
  399. static int bcm6362_pinctrl_get_group_pins(struct pinctrl_dev *pctldev,
  400. unsigned group, const unsigned **pins,
  401. unsigned *npins)
  402. {
  403. *pins = bcm6362_groups[group].pins;
  404. *npins = bcm6362_groups[group].npins;
  405. return 0;
  406. }
  407. static int bcm6362_pinctrl_get_func_count(struct pinctrl_dev *pctldev)
  408. {
  409. return ARRAY_SIZE(bcm6362_funcs);
  410. }
  411. static const char *bcm6362_pinctrl_get_func_name(struct pinctrl_dev *pctldev,
  412. unsigned selector)
  413. {
  414. return bcm6362_funcs[selector].name;
  415. }
  416. static int bcm6362_pinctrl_get_groups(struct pinctrl_dev *pctldev,
  417. unsigned selector,
  418. const char * const **groups,
  419. unsigned * const num_groups)
  420. {
  421. *groups = bcm6362_funcs[selector].groups;
  422. *num_groups = bcm6362_funcs[selector].num_groups;
  423. return 0;
  424. }
  425. static void bcm6362_set_gpio(struct bcm63xx_pinctrl *pc, unsigned pin)
  426. {
  427. const struct pinctrl_pin_desc *desc = &bcm6362_pins[pin];
  428. unsigned int basemode = (uintptr_t)desc->drv_data;
  429. unsigned int mask = bcm63xx_bank_pin(pin);
  430. if (basemode)
  431. regmap_update_bits(pc->regs, BCM6362_BASEMODE_REG, basemode, 0);
  432. if (pin < BCM63XX_BANK_GPIOS) {
  433. /* base mode 0 => gpio 1 => mux function */
  434. regmap_update_bits(pc->regs, BCM6362_MODE_REG, mask, 0);
  435. /* pins 0-23 might be muxed to led */
  436. if (pin < BCM6362_NUM_LEDS)
  437. regmap_update_bits(pc->regs, BCM6362_LED_REG, mask, 0);
  438. } else {
  439. /* ctrl reg 0 => wifi function 1 => gpio */
  440. regmap_update_bits(pc->regs, BCM6362_CTRL_REG, mask, mask);
  441. }
  442. }
  443. static int bcm6362_pinctrl_set_mux(struct pinctrl_dev *pctldev,
  444. unsigned selector, unsigned group)
  445. {
  446. struct bcm63xx_pinctrl *pc = pinctrl_dev_get_drvdata(pctldev);
  447. const struct pingroup *pg = &bcm6362_groups[group];
  448. const struct bcm6362_function *f = &bcm6362_funcs[selector];
  449. unsigned i;
  450. unsigned int reg;
  451. unsigned int val, mask;
  452. for (i = 0; i < pg->npins; i++)
  453. bcm6362_set_gpio(pc, pg->pins[i]);
  454. switch (f->reg) {
  455. case BCM6362_LEDCTRL:
  456. reg = BCM6362_LED_REG;
  457. mask = BIT(pg->pins[0]);
  458. val = BIT(pg->pins[0]);
  459. break;
  460. case BCM6362_MODE:
  461. reg = BCM6362_MODE_REG;
  462. mask = BIT(pg->pins[0]);
  463. val = BIT(pg->pins[0]);
  464. break;
  465. case BCM6362_CTRL:
  466. reg = BCM6362_CTRL_REG;
  467. mask = BIT(pg->pins[0]);
  468. val = 0;
  469. break;
  470. case BCM6362_BASEMODE:
  471. reg = BCM6362_BASEMODE_REG;
  472. mask = f->basemode_mask;
  473. val = f->basemode_mask;
  474. break;
  475. default:
  476. WARN_ON(1);
  477. return -EINVAL;
  478. }
  479. regmap_update_bits(pc->regs, reg, mask, val);
  480. return 0;
  481. }
  482. static int bcm6362_gpio_request_enable(struct pinctrl_dev *pctldev,
  483. struct pinctrl_gpio_range *range,
  484. unsigned offset)
  485. {
  486. struct bcm63xx_pinctrl *pc = pinctrl_dev_get_drvdata(pctldev);
  487. /* disable all functions using this pin */
  488. bcm6362_set_gpio(pc, offset);
  489. return 0;
  490. }
  491. static const struct pinctrl_ops bcm6362_pctl_ops = {
  492. .dt_free_map = pinctrl_utils_free_map,
  493. .dt_node_to_map = pinconf_generic_dt_node_to_map_pin,
  494. .get_group_name = bcm6362_pinctrl_get_group_name,
  495. .get_group_pins = bcm6362_pinctrl_get_group_pins,
  496. .get_groups_count = bcm6362_pinctrl_get_group_count,
  497. };
  498. static const struct pinmux_ops bcm6362_pmx_ops = {
  499. .get_function_groups = bcm6362_pinctrl_get_groups,
  500. .get_function_name = bcm6362_pinctrl_get_func_name,
  501. .get_functions_count = bcm6362_pinctrl_get_func_count,
  502. .gpio_request_enable = bcm6362_gpio_request_enable,
  503. .set_mux = bcm6362_pinctrl_set_mux,
  504. .strict = true,
  505. };
  506. static const struct bcm63xx_pinctrl_soc bcm6362_soc = {
  507. .ngpios = BCM6362_NUM_GPIOS,
  508. .npins = ARRAY_SIZE(bcm6362_pins),
  509. .pctl_ops = &bcm6362_pctl_ops,
  510. .pins = bcm6362_pins,
  511. .pmx_ops = &bcm6362_pmx_ops,
  512. };
  513. static int bcm6362_pinctrl_probe(struct platform_device *pdev)
  514. {
  515. return bcm63xx_pinctrl_probe(pdev, &bcm6362_soc, NULL);
  516. }
  517. static const struct of_device_id bcm6362_pinctrl_match[] = {
  518. { .compatible = "brcm,bcm6362-pinctrl", },
  519. { /* sentinel */ }
  520. };
  521. static struct platform_driver bcm6362_pinctrl_driver = {
  522. .probe = bcm6362_pinctrl_probe,
  523. .driver = {
  524. .name = "bcm6362-pinctrl",
  525. .of_match_table = bcm6362_pinctrl_match,
  526. },
  527. };
  528. builtin_platform_driver(bcm6362_pinctrl_driver);