pinctrl-imx6sl.c 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395
  1. /*
  2. * Freescale imx6sl 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 imx6sl_pads {
  19. MX6SL_PAD_RESERVE0 = 0,
  20. MX6SL_PAD_RESERVE1 = 1,
  21. MX6SL_PAD_RESERVE2 = 2,
  22. MX6SL_PAD_RESERVE3 = 3,
  23. MX6SL_PAD_RESERVE4 = 4,
  24. MX6SL_PAD_RESERVE5 = 5,
  25. MX6SL_PAD_RESERVE6 = 6,
  26. MX6SL_PAD_RESERVE7 = 7,
  27. MX6SL_PAD_RESERVE8 = 8,
  28. MX6SL_PAD_RESERVE9 = 9,
  29. MX6SL_PAD_RESERVE10 = 10,
  30. MX6SL_PAD_RESERVE11 = 11,
  31. MX6SL_PAD_RESERVE12 = 12,
  32. MX6SL_PAD_RESERVE13 = 13,
  33. MX6SL_PAD_RESERVE14 = 14,
  34. MX6SL_PAD_RESERVE15 = 15,
  35. MX6SL_PAD_RESERVE16 = 16,
  36. MX6SL_PAD_RESERVE17 = 17,
  37. MX6SL_PAD_RESERVE18 = 18,
  38. MX6SL_PAD_AUD_MCLK = 19,
  39. MX6SL_PAD_AUD_RXC = 20,
  40. MX6SL_PAD_AUD_RXD = 21,
  41. MX6SL_PAD_AUD_RXFS = 22,
  42. MX6SL_PAD_AUD_TXC = 23,
  43. MX6SL_PAD_AUD_TXD = 24,
  44. MX6SL_PAD_AUD_TXFS = 25,
  45. MX6SL_PAD_ECSPI1_MISO = 26,
  46. MX6SL_PAD_ECSPI1_MOSI = 27,
  47. MX6SL_PAD_ECSPI1_SCLK = 28,
  48. MX6SL_PAD_ECSPI1_SS0 = 29,
  49. MX6SL_PAD_ECSPI2_MISO = 30,
  50. MX6SL_PAD_ECSPI2_MOSI = 31,
  51. MX6SL_PAD_ECSPI2_SCLK = 32,
  52. MX6SL_PAD_ECSPI2_SS0 = 33,
  53. MX6SL_PAD_EPDC_BDR0 = 34,
  54. MX6SL_PAD_EPDC_BDR1 = 35,
  55. MX6SL_PAD_EPDC_D0 = 36,
  56. MX6SL_PAD_EPDC_D1 = 37,
  57. MX6SL_PAD_EPDC_D10 = 38,
  58. MX6SL_PAD_EPDC_D11 = 39,
  59. MX6SL_PAD_EPDC_D12 = 40,
  60. MX6SL_PAD_EPDC_D13 = 41,
  61. MX6SL_PAD_EPDC_D14 = 42,
  62. MX6SL_PAD_EPDC_D15 = 43,
  63. MX6SL_PAD_EPDC_D2 = 44,
  64. MX6SL_PAD_EPDC_D3 = 45,
  65. MX6SL_PAD_EPDC_D4 = 46,
  66. MX6SL_PAD_EPDC_D5 = 47,
  67. MX6SL_PAD_EPDC_D6 = 48,
  68. MX6SL_PAD_EPDC_D7 = 49,
  69. MX6SL_PAD_EPDC_D8 = 50,
  70. MX6SL_PAD_EPDC_D9 = 51,
  71. MX6SL_PAD_EPDC_GDCLK = 52,
  72. MX6SL_PAD_EPDC_GDOE = 53,
  73. MX6SL_PAD_EPDC_GDRL = 54,
  74. MX6SL_PAD_EPDC_GDSP = 55,
  75. MX6SL_PAD_EPDC_PWRCOM = 56,
  76. MX6SL_PAD_EPDC_PWRCTRL0 = 57,
  77. MX6SL_PAD_EPDC_PWRCTRL1 = 58,
  78. MX6SL_PAD_EPDC_PWRCTRL2 = 59,
  79. MX6SL_PAD_EPDC_PWRCTRL3 = 60,
  80. MX6SL_PAD_EPDC_PWRINT = 61,
  81. MX6SL_PAD_EPDC_PWRSTAT = 62,
  82. MX6SL_PAD_EPDC_PWRWAKEUP = 63,
  83. MX6SL_PAD_EPDC_SDCE0 = 64,
  84. MX6SL_PAD_EPDC_SDCE1 = 65,
  85. MX6SL_PAD_EPDC_SDCE2 = 66,
  86. MX6SL_PAD_EPDC_SDCE3 = 67,
  87. MX6SL_PAD_EPDC_SDCLK = 68,
  88. MX6SL_PAD_EPDC_SDLE = 69,
  89. MX6SL_PAD_EPDC_SDOE = 70,
  90. MX6SL_PAD_EPDC_SDSHR = 71,
  91. MX6SL_PAD_EPDC_VCOM0 = 72,
  92. MX6SL_PAD_EPDC_VCOM1 = 73,
  93. MX6SL_PAD_FEC_CRS_DV = 74,
  94. MX6SL_PAD_FEC_MDC = 75,
  95. MX6SL_PAD_FEC_MDIO = 76,
  96. MX6SL_PAD_FEC_REF_CLK = 77,
  97. MX6SL_PAD_FEC_RX_ER = 78,
  98. MX6SL_PAD_FEC_RXD0 = 79,
  99. MX6SL_PAD_FEC_RXD1 = 80,
  100. MX6SL_PAD_FEC_TX_CLK = 81,
  101. MX6SL_PAD_FEC_TX_EN = 82,
  102. MX6SL_PAD_FEC_TXD0 = 83,
  103. MX6SL_PAD_FEC_TXD1 = 84,
  104. MX6SL_PAD_HSIC_DAT = 85,
  105. MX6SL_PAD_HSIC_STROBE = 86,
  106. MX6SL_PAD_I2C1_SCL = 87,
  107. MX6SL_PAD_I2C1_SDA = 88,
  108. MX6SL_PAD_I2C2_SCL = 89,
  109. MX6SL_PAD_I2C2_SDA = 90,
  110. MX6SL_PAD_KEY_COL0 = 91,
  111. MX6SL_PAD_KEY_COL1 = 92,
  112. MX6SL_PAD_KEY_COL2 = 93,
  113. MX6SL_PAD_KEY_COL3 = 94,
  114. MX6SL_PAD_KEY_COL4 = 95,
  115. MX6SL_PAD_KEY_COL5 = 96,
  116. MX6SL_PAD_KEY_COL6 = 97,
  117. MX6SL_PAD_KEY_COL7 = 98,
  118. MX6SL_PAD_KEY_ROW0 = 99,
  119. MX6SL_PAD_KEY_ROW1 = 100,
  120. MX6SL_PAD_KEY_ROW2 = 101,
  121. MX6SL_PAD_KEY_ROW3 = 102,
  122. MX6SL_PAD_KEY_ROW4 = 103,
  123. MX6SL_PAD_KEY_ROW5 = 104,
  124. MX6SL_PAD_KEY_ROW6 = 105,
  125. MX6SL_PAD_KEY_ROW7 = 106,
  126. MX6SL_PAD_LCD_CLK = 107,
  127. MX6SL_PAD_LCD_DAT0 = 108,
  128. MX6SL_PAD_LCD_DAT1 = 109,
  129. MX6SL_PAD_LCD_DAT10 = 110,
  130. MX6SL_PAD_LCD_DAT11 = 111,
  131. MX6SL_PAD_LCD_DAT12 = 112,
  132. MX6SL_PAD_LCD_DAT13 = 113,
  133. MX6SL_PAD_LCD_DAT14 = 114,
  134. MX6SL_PAD_LCD_DAT15 = 115,
  135. MX6SL_PAD_LCD_DAT16 = 116,
  136. MX6SL_PAD_LCD_DAT17 = 117,
  137. MX6SL_PAD_LCD_DAT18 = 118,
  138. MX6SL_PAD_LCD_DAT19 = 119,
  139. MX6SL_PAD_LCD_DAT2 = 120,
  140. MX6SL_PAD_LCD_DAT20 = 121,
  141. MX6SL_PAD_LCD_DAT21 = 122,
  142. MX6SL_PAD_LCD_DAT22 = 123,
  143. MX6SL_PAD_LCD_DAT23 = 124,
  144. MX6SL_PAD_LCD_DAT3 = 125,
  145. MX6SL_PAD_LCD_DAT4 = 126,
  146. MX6SL_PAD_LCD_DAT5 = 127,
  147. MX6SL_PAD_LCD_DAT6 = 128,
  148. MX6SL_PAD_LCD_DAT7 = 129,
  149. MX6SL_PAD_LCD_DAT8 = 130,
  150. MX6SL_PAD_LCD_DAT9 = 131,
  151. MX6SL_PAD_LCD_ENABLE = 132,
  152. MX6SL_PAD_LCD_HSYNC = 133,
  153. MX6SL_PAD_LCD_RESET = 134,
  154. MX6SL_PAD_LCD_VSYNC = 135,
  155. MX6SL_PAD_PWM1 = 136,
  156. MX6SL_PAD_REF_CLK_24M = 137,
  157. MX6SL_PAD_REF_CLK_32K = 138,
  158. MX6SL_PAD_SD1_CLK = 139,
  159. MX6SL_PAD_SD1_CMD = 140,
  160. MX6SL_PAD_SD1_DAT0 = 141,
  161. MX6SL_PAD_SD1_DAT1 = 142,
  162. MX6SL_PAD_SD1_DAT2 = 143,
  163. MX6SL_PAD_SD1_DAT3 = 144,
  164. MX6SL_PAD_SD1_DAT4 = 145,
  165. MX6SL_PAD_SD1_DAT5 = 146,
  166. MX6SL_PAD_SD1_DAT6 = 147,
  167. MX6SL_PAD_SD1_DAT7 = 148,
  168. MX6SL_PAD_SD2_CLK = 149,
  169. MX6SL_PAD_SD2_CMD = 150,
  170. MX6SL_PAD_SD2_DAT0 = 151,
  171. MX6SL_PAD_SD2_DAT1 = 152,
  172. MX6SL_PAD_SD2_DAT2 = 153,
  173. MX6SL_PAD_SD2_DAT3 = 154,
  174. MX6SL_PAD_SD2_DAT4 = 155,
  175. MX6SL_PAD_SD2_DAT5 = 156,
  176. MX6SL_PAD_SD2_DAT6 = 157,
  177. MX6SL_PAD_SD2_DAT7 = 158,
  178. MX6SL_PAD_SD2_RST = 159,
  179. MX6SL_PAD_SD3_CLK = 160,
  180. MX6SL_PAD_SD3_CMD = 161,
  181. MX6SL_PAD_SD3_DAT0 = 162,
  182. MX6SL_PAD_SD3_DAT1 = 163,
  183. MX6SL_PAD_SD3_DAT2 = 164,
  184. MX6SL_PAD_SD3_DAT3 = 165,
  185. MX6SL_PAD_UART1_RXD = 166,
  186. MX6SL_PAD_UART1_TXD = 167,
  187. MX6SL_PAD_WDOG_B = 168,
  188. };
  189. /* Pad names for the pinmux subsystem */
  190. static const struct pinctrl_pin_desc imx6sl_pinctrl_pads[] = {
  191. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE0),
  192. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE1),
  193. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE2),
  194. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE3),
  195. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE4),
  196. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE5),
  197. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE6),
  198. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE7),
  199. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE8),
  200. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE9),
  201. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE10),
  202. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE11),
  203. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE12),
  204. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE13),
  205. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE14),
  206. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE15),
  207. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE16),
  208. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE17),
  209. IMX_PINCTRL_PIN(MX6SL_PAD_RESERVE18),
  210. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_MCLK),
  211. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_RXC),
  212. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_RXD),
  213. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_RXFS),
  214. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_TXC),
  215. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_TXD),
  216. IMX_PINCTRL_PIN(MX6SL_PAD_AUD_TXFS),
  217. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI1_MISO),
  218. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI1_MOSI),
  219. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI1_SCLK),
  220. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI1_SS0),
  221. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI2_MISO),
  222. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI2_MOSI),
  223. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI2_SCLK),
  224. IMX_PINCTRL_PIN(MX6SL_PAD_ECSPI2_SS0),
  225. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_BDR0),
  226. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_BDR1),
  227. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D0),
  228. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D1),
  229. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D10),
  230. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D11),
  231. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D12),
  232. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D13),
  233. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D14),
  234. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D15),
  235. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D2),
  236. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D3),
  237. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D4),
  238. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D5),
  239. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D6),
  240. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D7),
  241. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D8),
  242. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_D9),
  243. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_GDCLK),
  244. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_GDOE),
  245. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_GDRL),
  246. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_GDSP),
  247. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRCOM),
  248. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRCTRL0),
  249. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRCTRL1),
  250. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRCTRL2),
  251. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRCTRL3),
  252. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRINT),
  253. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRSTAT),
  254. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_PWRWAKEUP),
  255. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDCE0),
  256. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDCE1),
  257. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDCE2),
  258. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDCE3),
  259. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDCLK),
  260. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDLE),
  261. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDOE),
  262. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_SDSHR),
  263. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_VCOM0),
  264. IMX_PINCTRL_PIN(MX6SL_PAD_EPDC_VCOM1),
  265. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_CRS_DV),
  266. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_MDC),
  267. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_MDIO),
  268. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_REF_CLK),
  269. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_RX_ER),
  270. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_RXD0),
  271. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_RXD1),
  272. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_TX_CLK),
  273. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_TX_EN),
  274. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_TXD0),
  275. IMX_PINCTRL_PIN(MX6SL_PAD_FEC_TXD1),
  276. IMX_PINCTRL_PIN(MX6SL_PAD_HSIC_DAT),
  277. IMX_PINCTRL_PIN(MX6SL_PAD_HSIC_STROBE),
  278. IMX_PINCTRL_PIN(MX6SL_PAD_I2C1_SCL),
  279. IMX_PINCTRL_PIN(MX6SL_PAD_I2C1_SDA),
  280. IMX_PINCTRL_PIN(MX6SL_PAD_I2C2_SCL),
  281. IMX_PINCTRL_PIN(MX6SL_PAD_I2C2_SDA),
  282. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL0),
  283. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL1),
  284. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL2),
  285. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL3),
  286. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL4),
  287. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL5),
  288. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL6),
  289. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_COL7),
  290. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW0),
  291. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW1),
  292. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW2),
  293. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW3),
  294. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW4),
  295. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW5),
  296. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW6),
  297. IMX_PINCTRL_PIN(MX6SL_PAD_KEY_ROW7),
  298. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_CLK),
  299. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT0),
  300. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT1),
  301. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT10),
  302. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT11),
  303. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT12),
  304. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT13),
  305. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT14),
  306. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT15),
  307. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT16),
  308. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT17),
  309. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT18),
  310. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT19),
  311. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT2),
  312. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT20),
  313. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT21),
  314. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT22),
  315. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT23),
  316. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT3),
  317. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT4),
  318. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT5),
  319. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT6),
  320. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT7),
  321. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT8),
  322. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_DAT9),
  323. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_ENABLE),
  324. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_HSYNC),
  325. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_RESET),
  326. IMX_PINCTRL_PIN(MX6SL_PAD_LCD_VSYNC),
  327. IMX_PINCTRL_PIN(MX6SL_PAD_PWM1),
  328. IMX_PINCTRL_PIN(MX6SL_PAD_REF_CLK_24M),
  329. IMX_PINCTRL_PIN(MX6SL_PAD_REF_CLK_32K),
  330. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_CLK),
  331. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_CMD),
  332. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT0),
  333. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT1),
  334. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT2),
  335. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT3),
  336. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT4),
  337. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT5),
  338. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT6),
  339. IMX_PINCTRL_PIN(MX6SL_PAD_SD1_DAT7),
  340. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_CLK),
  341. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_CMD),
  342. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT0),
  343. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT1),
  344. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT2),
  345. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT3),
  346. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT4),
  347. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT5),
  348. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT6),
  349. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_DAT7),
  350. IMX_PINCTRL_PIN(MX6SL_PAD_SD2_RST),
  351. IMX_PINCTRL_PIN(MX6SL_PAD_SD3_CLK),
  352. IMX_PINCTRL_PIN(MX6SL_PAD_SD3_CMD),
  353. IMX_PINCTRL_PIN(MX6SL_PAD_SD3_DAT0),
  354. IMX_PINCTRL_PIN(MX6SL_PAD_SD3_DAT1),
  355. IMX_PINCTRL_PIN(MX6SL_PAD_SD3_DAT2),
  356. IMX_PINCTRL_PIN(MX6SL_PAD_SD3_DAT3),
  357. IMX_PINCTRL_PIN(MX6SL_PAD_UART1_RXD),
  358. IMX_PINCTRL_PIN(MX6SL_PAD_UART1_TXD),
  359. IMX_PINCTRL_PIN(MX6SL_PAD_WDOG_B),
  360. };
  361. static struct imx_pinctrl_soc_info imx6sl_pinctrl_info = {
  362. .pins = imx6sl_pinctrl_pads,
  363. .npins = ARRAY_SIZE(imx6sl_pinctrl_pads),
  364. .gpr_compatible = "fsl,imx6sl-iomuxc-gpr",
  365. };
  366. static const struct of_device_id imx6sl_pinctrl_of_match[] = {
  367. { .compatible = "fsl,imx6sl-iomuxc", },
  368. { /* sentinel */ }
  369. };
  370. static int imx6sl_pinctrl_probe(struct platform_device *pdev)
  371. {
  372. return imx_pinctrl_probe(pdev, &imx6sl_pinctrl_info);
  373. }
  374. static struct platform_driver imx6sl_pinctrl_driver = {
  375. .driver = {
  376. .name = "imx6sl-pinctrl",
  377. .of_match_table = imx6sl_pinctrl_of_match,
  378. },
  379. .probe = imx6sl_pinctrl_probe,
  380. };
  381. static int __init imx6sl_pinctrl_init(void)
  382. {
  383. return platform_driver_register(&imx6sl_pinctrl_driver);
  384. }
  385. arch_initcall(imx6sl_pinctrl_init);