pinctrl-imx6dl.c 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489
  1. /*
  2. * Freescale imx6dl pinctrl driver
  3. *
  4. * Author: Shawn Guo <shawn.guo@linaro.org>
  5. * Copyright (C) 2013 Freescale Semiconductor, Inc.
  6. *
  7. * This program is free software; you can redistribute it and/or modify
  8. * it under the terms of the GNU General Public License version 2 as
  9. * published by the Free Software Foundation.
  10. */
  11. #include <linux/err.h>
  12. #include <linux/init.h>
  13. #include <linux/io.h>
  14. #include <linux/of.h>
  15. #include <linux/of_device.h>
  16. #include <linux/pinctrl/pinctrl.h>
  17. #include "pinctrl-imx.h"
  18. enum imx6dl_pads {
  19. MX6DL_PAD_RESERVE0 = 0,
  20. MX6DL_PAD_RESERVE1 = 1,
  21. MX6DL_PAD_RESERVE2 = 2,
  22. MX6DL_PAD_RESERVE3 = 3,
  23. MX6DL_PAD_RESERVE4 = 4,
  24. MX6DL_PAD_RESERVE5 = 5,
  25. MX6DL_PAD_RESERVE6 = 6,
  26. MX6DL_PAD_RESERVE7 = 7,
  27. MX6DL_PAD_RESERVE8 = 8,
  28. MX6DL_PAD_RESERVE9 = 9,
  29. MX6DL_PAD_RESERVE10 = 10,
  30. MX6DL_PAD_RESERVE11 = 11,
  31. MX6DL_PAD_RESERVE12 = 12,
  32. MX6DL_PAD_RESERVE13 = 13,
  33. MX6DL_PAD_RESERVE14 = 14,
  34. MX6DL_PAD_RESERVE15 = 15,
  35. MX6DL_PAD_RESERVE16 = 16,
  36. MX6DL_PAD_RESERVE17 = 17,
  37. MX6DL_PAD_RESERVE18 = 18,
  38. MX6DL_PAD_CSI0_DAT10 = 19,
  39. MX6DL_PAD_CSI0_DAT11 = 20,
  40. MX6DL_PAD_CSI0_DAT12 = 21,
  41. MX6DL_PAD_CSI0_DAT13 = 22,
  42. MX6DL_PAD_CSI0_DAT14 = 23,
  43. MX6DL_PAD_CSI0_DAT15 = 24,
  44. MX6DL_PAD_CSI0_DAT16 = 25,
  45. MX6DL_PAD_CSI0_DAT17 = 26,
  46. MX6DL_PAD_CSI0_DAT18 = 27,
  47. MX6DL_PAD_CSI0_DAT19 = 28,
  48. MX6DL_PAD_CSI0_DAT4 = 29,
  49. MX6DL_PAD_CSI0_DAT5 = 30,
  50. MX6DL_PAD_CSI0_DAT6 = 31,
  51. MX6DL_PAD_CSI0_DAT7 = 32,
  52. MX6DL_PAD_CSI0_DAT8 = 33,
  53. MX6DL_PAD_CSI0_DAT9 = 34,
  54. MX6DL_PAD_CSI0_DATA_EN = 35,
  55. MX6DL_PAD_CSI0_MCLK = 36,
  56. MX6DL_PAD_CSI0_PIXCLK = 37,
  57. MX6DL_PAD_CSI0_VSYNC = 38,
  58. MX6DL_PAD_DI0_DISP_CLK = 39,
  59. MX6DL_PAD_DI0_PIN15 = 40,
  60. MX6DL_PAD_DI0_PIN2 = 41,
  61. MX6DL_PAD_DI0_PIN3 = 42,
  62. MX6DL_PAD_DI0_PIN4 = 43,
  63. MX6DL_PAD_DISP0_DAT0 = 44,
  64. MX6DL_PAD_DISP0_DAT1 = 45,
  65. MX6DL_PAD_DISP0_DAT10 = 46,
  66. MX6DL_PAD_DISP0_DAT11 = 47,
  67. MX6DL_PAD_DISP0_DAT12 = 48,
  68. MX6DL_PAD_DISP0_DAT13 = 49,
  69. MX6DL_PAD_DISP0_DAT14 = 50,
  70. MX6DL_PAD_DISP0_DAT15 = 51,
  71. MX6DL_PAD_DISP0_DAT16 = 52,
  72. MX6DL_PAD_DISP0_DAT17 = 53,
  73. MX6DL_PAD_DISP0_DAT18 = 54,
  74. MX6DL_PAD_DISP0_DAT19 = 55,
  75. MX6DL_PAD_DISP0_DAT2 = 56,
  76. MX6DL_PAD_DISP0_DAT20 = 57,
  77. MX6DL_PAD_DISP0_DAT21 = 58,
  78. MX6DL_PAD_DISP0_DAT22 = 59,
  79. MX6DL_PAD_DISP0_DAT23 = 60,
  80. MX6DL_PAD_DISP0_DAT3 = 61,
  81. MX6DL_PAD_DISP0_DAT4 = 62,
  82. MX6DL_PAD_DISP0_DAT5 = 63,
  83. MX6DL_PAD_DISP0_DAT6 = 64,
  84. MX6DL_PAD_DISP0_DAT7 = 65,
  85. MX6DL_PAD_DISP0_DAT8 = 66,
  86. MX6DL_PAD_DISP0_DAT9 = 67,
  87. MX6DL_PAD_EIM_A16 = 68,
  88. MX6DL_PAD_EIM_A17 = 69,
  89. MX6DL_PAD_EIM_A18 = 70,
  90. MX6DL_PAD_EIM_A19 = 71,
  91. MX6DL_PAD_EIM_A20 = 72,
  92. MX6DL_PAD_EIM_A21 = 73,
  93. MX6DL_PAD_EIM_A22 = 74,
  94. MX6DL_PAD_EIM_A23 = 75,
  95. MX6DL_PAD_EIM_A24 = 76,
  96. MX6DL_PAD_EIM_A25 = 77,
  97. MX6DL_PAD_EIM_BCLK = 78,
  98. MX6DL_PAD_EIM_CS0 = 79,
  99. MX6DL_PAD_EIM_CS1 = 80,
  100. MX6DL_PAD_EIM_D16 = 81,
  101. MX6DL_PAD_EIM_D17 = 82,
  102. MX6DL_PAD_EIM_D18 = 83,
  103. MX6DL_PAD_EIM_D19 = 84,
  104. MX6DL_PAD_EIM_D20 = 85,
  105. MX6DL_PAD_EIM_D21 = 86,
  106. MX6DL_PAD_EIM_D22 = 87,
  107. MX6DL_PAD_EIM_D23 = 88,
  108. MX6DL_PAD_EIM_D24 = 89,
  109. MX6DL_PAD_EIM_D25 = 90,
  110. MX6DL_PAD_EIM_D26 = 91,
  111. MX6DL_PAD_EIM_D27 = 92,
  112. MX6DL_PAD_EIM_D28 = 93,
  113. MX6DL_PAD_EIM_D29 = 94,
  114. MX6DL_PAD_EIM_D30 = 95,
  115. MX6DL_PAD_EIM_D31 = 96,
  116. MX6DL_PAD_EIM_DA0 = 97,
  117. MX6DL_PAD_EIM_DA1 = 98,
  118. MX6DL_PAD_EIM_DA10 = 99,
  119. MX6DL_PAD_EIM_DA11 = 100,
  120. MX6DL_PAD_EIM_DA12 = 101,
  121. MX6DL_PAD_EIM_DA13 = 102,
  122. MX6DL_PAD_EIM_DA14 = 103,
  123. MX6DL_PAD_EIM_DA15 = 104,
  124. MX6DL_PAD_EIM_DA2 = 105,
  125. MX6DL_PAD_EIM_DA3 = 106,
  126. MX6DL_PAD_EIM_DA4 = 107,
  127. MX6DL_PAD_EIM_DA5 = 108,
  128. MX6DL_PAD_EIM_DA6 = 109,
  129. MX6DL_PAD_EIM_DA7 = 110,
  130. MX6DL_PAD_EIM_DA8 = 111,
  131. MX6DL_PAD_EIM_DA9 = 112,
  132. MX6DL_PAD_EIM_EB0 = 113,
  133. MX6DL_PAD_EIM_EB1 = 114,
  134. MX6DL_PAD_EIM_EB2 = 115,
  135. MX6DL_PAD_EIM_EB3 = 116,
  136. MX6DL_PAD_EIM_LBA = 117,
  137. MX6DL_PAD_EIM_OE = 118,
  138. MX6DL_PAD_EIM_RW = 119,
  139. MX6DL_PAD_EIM_WAIT = 120,
  140. MX6DL_PAD_ENET_CRS_DV = 121,
  141. MX6DL_PAD_ENET_MDC = 122,
  142. MX6DL_PAD_ENET_MDIO = 123,
  143. MX6DL_PAD_ENET_REF_CLK = 124,
  144. MX6DL_PAD_ENET_RX_ER = 125,
  145. MX6DL_PAD_ENET_RXD0 = 126,
  146. MX6DL_PAD_ENET_RXD1 = 127,
  147. MX6DL_PAD_ENET_TX_EN = 128,
  148. MX6DL_PAD_ENET_TXD0 = 129,
  149. MX6DL_PAD_ENET_TXD1 = 130,
  150. MX6DL_PAD_GPIO_0 = 131,
  151. MX6DL_PAD_GPIO_1 = 132,
  152. MX6DL_PAD_GPIO_16 = 133,
  153. MX6DL_PAD_GPIO_17 = 134,
  154. MX6DL_PAD_GPIO_18 = 135,
  155. MX6DL_PAD_GPIO_19 = 136,
  156. MX6DL_PAD_GPIO_2 = 137,
  157. MX6DL_PAD_GPIO_3 = 138,
  158. MX6DL_PAD_GPIO_4 = 139,
  159. MX6DL_PAD_GPIO_5 = 140,
  160. MX6DL_PAD_GPIO_6 = 141,
  161. MX6DL_PAD_GPIO_7 = 142,
  162. MX6DL_PAD_GPIO_8 = 143,
  163. MX6DL_PAD_GPIO_9 = 144,
  164. MX6DL_PAD_KEY_COL0 = 145,
  165. MX6DL_PAD_KEY_COL1 = 146,
  166. MX6DL_PAD_KEY_COL2 = 147,
  167. MX6DL_PAD_KEY_COL3 = 148,
  168. MX6DL_PAD_KEY_COL4 = 149,
  169. MX6DL_PAD_KEY_ROW0 = 150,
  170. MX6DL_PAD_KEY_ROW1 = 151,
  171. MX6DL_PAD_KEY_ROW2 = 152,
  172. MX6DL_PAD_KEY_ROW3 = 153,
  173. MX6DL_PAD_KEY_ROW4 = 154,
  174. MX6DL_PAD_NANDF_ALE = 155,
  175. MX6DL_PAD_NANDF_CLE = 156,
  176. MX6DL_PAD_NANDF_CS0 = 157,
  177. MX6DL_PAD_NANDF_CS1 = 158,
  178. MX6DL_PAD_NANDF_CS2 = 159,
  179. MX6DL_PAD_NANDF_CS3 = 160,
  180. MX6DL_PAD_NANDF_D0 = 161,
  181. MX6DL_PAD_NANDF_D1 = 162,
  182. MX6DL_PAD_NANDF_D2 = 163,
  183. MX6DL_PAD_NANDF_D3 = 164,
  184. MX6DL_PAD_NANDF_D4 = 165,
  185. MX6DL_PAD_NANDF_D5 = 166,
  186. MX6DL_PAD_NANDF_D6 = 167,
  187. MX6DL_PAD_NANDF_D7 = 168,
  188. MX6DL_PAD_NANDF_RB0 = 169,
  189. MX6DL_PAD_NANDF_WP_B = 170,
  190. MX6DL_PAD_RGMII_RD0 = 171,
  191. MX6DL_PAD_RGMII_RD1 = 172,
  192. MX6DL_PAD_RGMII_RD2 = 173,
  193. MX6DL_PAD_RGMII_RD3 = 174,
  194. MX6DL_PAD_RGMII_RX_CTL = 175,
  195. MX6DL_PAD_RGMII_RXC = 176,
  196. MX6DL_PAD_RGMII_TD0 = 177,
  197. MX6DL_PAD_RGMII_TD1 = 178,
  198. MX6DL_PAD_RGMII_TD2 = 179,
  199. MX6DL_PAD_RGMII_TD3 = 180,
  200. MX6DL_PAD_RGMII_TX_CTL = 181,
  201. MX6DL_PAD_RGMII_TXC = 182,
  202. MX6DL_PAD_SD1_CLK = 183,
  203. MX6DL_PAD_SD1_CMD = 184,
  204. MX6DL_PAD_SD1_DAT0 = 185,
  205. MX6DL_PAD_SD1_DAT1 = 186,
  206. MX6DL_PAD_SD1_DAT2 = 187,
  207. MX6DL_PAD_SD1_DAT3 = 188,
  208. MX6DL_PAD_SD2_CLK = 189,
  209. MX6DL_PAD_SD2_CMD = 190,
  210. MX6DL_PAD_SD2_DAT0 = 191,
  211. MX6DL_PAD_SD2_DAT1 = 192,
  212. MX6DL_PAD_SD2_DAT2 = 193,
  213. MX6DL_PAD_SD2_DAT3 = 194,
  214. MX6DL_PAD_SD3_CLK = 195,
  215. MX6DL_PAD_SD3_CMD = 196,
  216. MX6DL_PAD_SD3_DAT0 = 197,
  217. MX6DL_PAD_SD3_DAT1 = 198,
  218. MX6DL_PAD_SD3_DAT2 = 199,
  219. MX6DL_PAD_SD3_DAT3 = 200,
  220. MX6DL_PAD_SD3_DAT4 = 201,
  221. MX6DL_PAD_SD3_DAT5 = 202,
  222. MX6DL_PAD_SD3_DAT6 = 203,
  223. MX6DL_PAD_SD3_DAT7 = 204,
  224. MX6DL_PAD_SD3_RST = 205,
  225. MX6DL_PAD_SD4_CLK = 206,
  226. MX6DL_PAD_SD4_CMD = 207,
  227. MX6DL_PAD_SD4_DAT0 = 208,
  228. MX6DL_PAD_SD4_DAT1 = 209,
  229. MX6DL_PAD_SD4_DAT2 = 210,
  230. MX6DL_PAD_SD4_DAT3 = 211,
  231. MX6DL_PAD_SD4_DAT4 = 212,
  232. MX6DL_PAD_SD4_DAT5 = 213,
  233. MX6DL_PAD_SD4_DAT6 = 214,
  234. MX6DL_PAD_SD4_DAT7 = 215,
  235. };
  236. /* Pad names for the pinmux subsystem */
  237. static const struct pinctrl_pin_desc imx6dl_pinctrl_pads[] = {
  238. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE0),
  239. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE1),
  240. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE2),
  241. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE3),
  242. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE4),
  243. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE5),
  244. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE6),
  245. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE7),
  246. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE8),
  247. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE9),
  248. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE10),
  249. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE11),
  250. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE12),
  251. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE13),
  252. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE14),
  253. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE15),
  254. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE16),
  255. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE17),
  256. IMX_PINCTRL_PIN(MX6DL_PAD_RESERVE18),
  257. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT10),
  258. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT11),
  259. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT12),
  260. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT13),
  261. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT14),
  262. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT15),
  263. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT16),
  264. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT17),
  265. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT18),
  266. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT19),
  267. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT4),
  268. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT5),
  269. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT6),
  270. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT7),
  271. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT8),
  272. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DAT9),
  273. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_DATA_EN),
  274. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_MCLK),
  275. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_PIXCLK),
  276. IMX_PINCTRL_PIN(MX6DL_PAD_CSI0_VSYNC),
  277. IMX_PINCTRL_PIN(MX6DL_PAD_DI0_DISP_CLK),
  278. IMX_PINCTRL_PIN(MX6DL_PAD_DI0_PIN15),
  279. IMX_PINCTRL_PIN(MX6DL_PAD_DI0_PIN2),
  280. IMX_PINCTRL_PIN(MX6DL_PAD_DI0_PIN3),
  281. IMX_PINCTRL_PIN(MX6DL_PAD_DI0_PIN4),
  282. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT0),
  283. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT1),
  284. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT10),
  285. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT11),
  286. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT12),
  287. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT13),
  288. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT14),
  289. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT15),
  290. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT16),
  291. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT17),
  292. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT18),
  293. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT19),
  294. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT2),
  295. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT20),
  296. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT21),
  297. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT22),
  298. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT23),
  299. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT3),
  300. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT4),
  301. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT5),
  302. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT6),
  303. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT7),
  304. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT8),
  305. IMX_PINCTRL_PIN(MX6DL_PAD_DISP0_DAT9),
  306. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A16),
  307. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A17),
  308. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A18),
  309. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A19),
  310. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A20),
  311. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A21),
  312. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A22),
  313. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A23),
  314. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A24),
  315. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_A25),
  316. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_BCLK),
  317. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_CS0),
  318. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_CS1),
  319. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D16),
  320. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D17),
  321. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D18),
  322. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D19),
  323. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D20),
  324. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D21),
  325. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D22),
  326. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D23),
  327. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D24),
  328. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D25),
  329. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D26),
  330. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D27),
  331. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D28),
  332. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D29),
  333. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D30),
  334. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_D31),
  335. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA0),
  336. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA1),
  337. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA10),
  338. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA11),
  339. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA12),
  340. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA13),
  341. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA14),
  342. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA15),
  343. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA2),
  344. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA3),
  345. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA4),
  346. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA5),
  347. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA6),
  348. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA7),
  349. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA8),
  350. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_DA9),
  351. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_EB0),
  352. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_EB1),
  353. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_EB2),
  354. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_EB3),
  355. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_LBA),
  356. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_OE),
  357. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_RW),
  358. IMX_PINCTRL_PIN(MX6DL_PAD_EIM_WAIT),
  359. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_CRS_DV),
  360. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_MDC),
  361. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_MDIO),
  362. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_REF_CLK),
  363. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_RX_ER),
  364. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_RXD0),
  365. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_RXD1),
  366. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_TX_EN),
  367. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_TXD0),
  368. IMX_PINCTRL_PIN(MX6DL_PAD_ENET_TXD1),
  369. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_0),
  370. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_1),
  371. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_16),
  372. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_17),
  373. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_18),
  374. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_19),
  375. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_2),
  376. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_3),
  377. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_4),
  378. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_5),
  379. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_6),
  380. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_7),
  381. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_8),
  382. IMX_PINCTRL_PIN(MX6DL_PAD_GPIO_9),
  383. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_COL0),
  384. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_COL1),
  385. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_COL2),
  386. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_COL3),
  387. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_COL4),
  388. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_ROW0),
  389. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_ROW1),
  390. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_ROW2),
  391. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_ROW3),
  392. IMX_PINCTRL_PIN(MX6DL_PAD_KEY_ROW4),
  393. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_ALE),
  394. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_CLE),
  395. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_CS0),
  396. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_CS1),
  397. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_CS2),
  398. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_CS3),
  399. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D0),
  400. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D1),
  401. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D2),
  402. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D3),
  403. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D4),
  404. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D5),
  405. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D6),
  406. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_D7),
  407. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_RB0),
  408. IMX_PINCTRL_PIN(MX6DL_PAD_NANDF_WP_B),
  409. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_RD0),
  410. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_RD1),
  411. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_RD2),
  412. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_RD3),
  413. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_RX_CTL),
  414. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_RXC),
  415. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_TD0),
  416. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_TD1),
  417. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_TD2),
  418. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_TD3),
  419. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_TX_CTL),
  420. IMX_PINCTRL_PIN(MX6DL_PAD_RGMII_TXC),
  421. IMX_PINCTRL_PIN(MX6DL_PAD_SD1_CLK),
  422. IMX_PINCTRL_PIN(MX6DL_PAD_SD1_CMD),
  423. IMX_PINCTRL_PIN(MX6DL_PAD_SD1_DAT0),
  424. IMX_PINCTRL_PIN(MX6DL_PAD_SD1_DAT1),
  425. IMX_PINCTRL_PIN(MX6DL_PAD_SD1_DAT2),
  426. IMX_PINCTRL_PIN(MX6DL_PAD_SD1_DAT3),
  427. IMX_PINCTRL_PIN(MX6DL_PAD_SD2_CLK),
  428. IMX_PINCTRL_PIN(MX6DL_PAD_SD2_CMD),
  429. IMX_PINCTRL_PIN(MX6DL_PAD_SD2_DAT0),
  430. IMX_PINCTRL_PIN(MX6DL_PAD_SD2_DAT1),
  431. IMX_PINCTRL_PIN(MX6DL_PAD_SD2_DAT2),
  432. IMX_PINCTRL_PIN(MX6DL_PAD_SD2_DAT3),
  433. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_CLK),
  434. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_CMD),
  435. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT0),
  436. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT1),
  437. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT2),
  438. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT3),
  439. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT4),
  440. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT5),
  441. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT6),
  442. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_DAT7),
  443. IMX_PINCTRL_PIN(MX6DL_PAD_SD3_RST),
  444. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_CLK),
  445. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_CMD),
  446. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT0),
  447. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT1),
  448. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT2),
  449. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT3),
  450. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT4),
  451. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT5),
  452. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT6),
  453. IMX_PINCTRL_PIN(MX6DL_PAD_SD4_DAT7),
  454. };
  455. static struct imx_pinctrl_soc_info imx6dl_pinctrl_info = {
  456. .pins = imx6dl_pinctrl_pads,
  457. .npins = ARRAY_SIZE(imx6dl_pinctrl_pads),
  458. .gpr_compatible = "fsl,imx6q-iomuxc-gpr",
  459. };
  460. static const struct of_device_id imx6dl_pinctrl_of_match[] = {
  461. { .compatible = "fsl,imx6dl-iomuxc", },
  462. { /* sentinel */ }
  463. };
  464. static int imx6dl_pinctrl_probe(struct platform_device *pdev)
  465. {
  466. return imx_pinctrl_probe(pdev, &imx6dl_pinctrl_info);
  467. }
  468. static struct platform_driver imx6dl_pinctrl_driver = {
  469. .driver = {
  470. .name = "imx6dl-pinctrl",
  471. .of_match_table = imx6dl_pinctrl_of_match,
  472. },
  473. .probe = imx6dl_pinctrl_probe,
  474. };
  475. static int __init imx6dl_pinctrl_init(void)
  476. {
  477. return platform_driver_register(&imx6dl_pinctrl_driver);
  478. }
  479. arch_initcall(imx6dl_pinctrl_init);