Linux 4.16.11
[linux/fpc-iii.git] / drivers / pinctrl / uniphier / pinctrl-uniphier-pxs3.c
blobdbe94a9a03535968b93f350f40a6a6f6c5a61334
1 /*
2 * Copyright (C) 2017 Socionext Inc.
3 * Author: Masahiro Yamada <yamada.masahiro@socionext.com>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
16 #include <linux/init.h>
17 #include <linux/kernel.h>
18 #include <linux/pinctrl/pinctrl.h>
19 #include <linux/platform_device.h>
21 #include "pinctrl-uniphier.h"
23 static const struct pinctrl_pin_desc uniphier_pxs3_pins[] = {
24 UNIPHIER_PINCTRL_PIN(0, "LPST", UNIPHIER_PIN_IECTRL_EXIST,
25 0, UNIPHIER_PIN_DRV_3BIT,
26 0, UNIPHIER_PIN_PULL_DOWN),
27 UNIPHIER_PINCTRL_PIN(1, "ED0", UNIPHIER_PIN_IECTRL_EXIST,
28 1, UNIPHIER_PIN_DRV_3BIT,
29 1, UNIPHIER_PIN_PULL_DOWN),
30 UNIPHIER_PINCTRL_PIN(2, "ED1", UNIPHIER_PIN_IECTRL_EXIST,
31 2, UNIPHIER_PIN_DRV_3BIT,
32 2, UNIPHIER_PIN_PULL_DOWN),
33 UNIPHIER_PINCTRL_PIN(3, "ED2", UNIPHIER_PIN_IECTRL_EXIST,
34 3, UNIPHIER_PIN_DRV_3BIT,
35 3, UNIPHIER_PIN_PULL_DOWN),
36 UNIPHIER_PINCTRL_PIN(4, "ED3", UNIPHIER_PIN_IECTRL_EXIST,
37 4, UNIPHIER_PIN_DRV_3BIT,
38 4, UNIPHIER_PIN_PULL_DOWN),
39 UNIPHIER_PINCTRL_PIN(5, "ED4", UNIPHIER_PIN_IECTRL_EXIST,
40 5, UNIPHIER_PIN_DRV_3BIT,
41 5, UNIPHIER_PIN_PULL_DOWN),
42 UNIPHIER_PINCTRL_PIN(6, "ED5", UNIPHIER_PIN_IECTRL_EXIST,
43 6, UNIPHIER_PIN_DRV_3BIT,
44 6, UNIPHIER_PIN_PULL_DOWN),
45 UNIPHIER_PINCTRL_PIN(7, "ED6", UNIPHIER_PIN_IECTRL_EXIST,
46 7, UNIPHIER_PIN_DRV_3BIT,
47 7, UNIPHIER_PIN_PULL_DOWN),
48 UNIPHIER_PINCTRL_PIN(8, "ED7", UNIPHIER_PIN_IECTRL_EXIST,
49 8, UNIPHIER_PIN_DRV_3BIT,
50 8, UNIPHIER_PIN_PULL_DOWN),
51 UNIPHIER_PINCTRL_PIN(9, "XERWE0", UNIPHIER_PIN_IECTRL_EXIST,
52 9, UNIPHIER_PIN_DRV_3BIT,
53 9, UNIPHIER_PIN_PULL_DOWN),
54 UNIPHIER_PINCTRL_PIN(10, "XERWE1", UNIPHIER_PIN_IECTRL_EXIST,
55 10, UNIPHIER_PIN_DRV_3BIT,
56 10, UNIPHIER_PIN_PULL_DOWN),
57 UNIPHIER_PINCTRL_PIN(11, "ERXW", UNIPHIER_PIN_IECTRL_EXIST,
58 11, UNIPHIER_PIN_DRV_3BIT,
59 11, UNIPHIER_PIN_PULL_DOWN),
60 UNIPHIER_PINCTRL_PIN(12, "ES0", UNIPHIER_PIN_IECTRL_EXIST,
61 12, UNIPHIER_PIN_DRV_3BIT,
62 12, UNIPHIER_PIN_PULL_DOWN),
63 UNIPHIER_PINCTRL_PIN(13, "ES1", UNIPHIER_PIN_IECTRL_EXIST,
64 13, UNIPHIER_PIN_DRV_3BIT,
65 13, UNIPHIER_PIN_PULL_DOWN),
66 UNIPHIER_PINCTRL_PIN(14, "ES2", UNIPHIER_PIN_IECTRL_EXIST,
67 14, UNIPHIER_PIN_DRV_3BIT,
68 14, UNIPHIER_PIN_PULL_DOWN),
69 UNIPHIER_PINCTRL_PIN(15, "XECS1", UNIPHIER_PIN_IECTRL_EXIST,
70 15, UNIPHIER_PIN_DRV_3BIT,
71 15, UNIPHIER_PIN_PULL_UP),
72 UNIPHIER_PINCTRL_PIN(16, "XNFWP", UNIPHIER_PIN_IECTRL_EXIST,
73 16, UNIPHIER_PIN_DRV_3BIT,
74 16, UNIPHIER_PIN_PULL_DOWN),
75 UNIPHIER_PINCTRL_PIN(17, "XNFCE0", UNIPHIER_PIN_IECTRL_EXIST,
76 17, UNIPHIER_PIN_DRV_3BIT,
77 17, UNIPHIER_PIN_PULL_UP),
78 UNIPHIER_PINCTRL_PIN(18, "NFRYBY0", UNIPHIER_PIN_IECTRL_EXIST,
79 18, UNIPHIER_PIN_DRV_3BIT,
80 18, UNIPHIER_PIN_PULL_UP),
81 UNIPHIER_PINCTRL_PIN(19, "XNFRE", UNIPHIER_PIN_IECTRL_EXIST,
82 19, UNIPHIER_PIN_DRV_3BIT,
83 19, UNIPHIER_PIN_PULL_UP),
84 UNIPHIER_PINCTRL_PIN(20, "XNFWE", UNIPHIER_PIN_IECTRL_EXIST,
85 20, UNIPHIER_PIN_DRV_3BIT,
86 20, UNIPHIER_PIN_PULL_UP),
87 UNIPHIER_PINCTRL_PIN(21, "NFALE", UNIPHIER_PIN_IECTRL_EXIST,
88 21, UNIPHIER_PIN_DRV_3BIT,
89 21, UNIPHIER_PIN_PULL_UP),
90 UNIPHIER_PINCTRL_PIN(22, "NFCLE", UNIPHIER_PIN_IECTRL_EXIST,
91 22, UNIPHIER_PIN_DRV_3BIT,
92 22, UNIPHIER_PIN_PULL_UP),
93 UNIPHIER_PINCTRL_PIN(23, "NFD0", UNIPHIER_PIN_IECTRL_EXIST,
94 23, UNIPHIER_PIN_DRV_3BIT,
95 23, UNIPHIER_PIN_PULL_UP),
96 UNIPHIER_PINCTRL_PIN(24, "NFD1", UNIPHIER_PIN_IECTRL_EXIST,
97 24, UNIPHIER_PIN_DRV_3BIT,
98 24, UNIPHIER_PIN_PULL_UP),
99 UNIPHIER_PINCTRL_PIN(25, "NFD2", UNIPHIER_PIN_IECTRL_EXIST,
100 25, UNIPHIER_PIN_DRV_3BIT,
101 25, UNIPHIER_PIN_PULL_UP),
102 UNIPHIER_PINCTRL_PIN(26, "NFD3", UNIPHIER_PIN_IECTRL_EXIST,
103 26, UNIPHIER_PIN_DRV_3BIT,
104 26, UNIPHIER_PIN_PULL_UP),
105 UNIPHIER_PINCTRL_PIN(27, "NFD4", UNIPHIER_PIN_IECTRL_EXIST,
106 27, UNIPHIER_PIN_DRV_3BIT,
107 27, UNIPHIER_PIN_PULL_UP),
108 UNIPHIER_PINCTRL_PIN(28, "NFD5", UNIPHIER_PIN_IECTRL_EXIST,
109 28, UNIPHIER_PIN_DRV_3BIT,
110 28, UNIPHIER_PIN_PULL_UP),
111 UNIPHIER_PINCTRL_PIN(29, "NFD6", UNIPHIER_PIN_IECTRL_EXIST,
112 29, UNIPHIER_PIN_DRV_3BIT,
113 29, UNIPHIER_PIN_PULL_UP),
114 UNIPHIER_PINCTRL_PIN(30, "NFD7", UNIPHIER_PIN_IECTRL_EXIST,
115 30, UNIPHIER_PIN_DRV_3BIT,
116 30, UNIPHIER_PIN_PULL_UP),
117 UNIPHIER_PINCTRL_PIN(31, "XERST", UNIPHIER_PIN_IECTRL_EXIST,
118 0, UNIPHIER_PIN_DRV_2BIT,
119 31, UNIPHIER_PIN_PULL_DOWN),
120 UNIPHIER_PINCTRL_PIN(32, "MMCCLK", UNIPHIER_PIN_IECTRL_EXIST,
121 1, UNIPHIER_PIN_DRV_2BIT,
122 32, UNIPHIER_PIN_PULL_DOWN),
123 UNIPHIER_PINCTRL_PIN(33, "MMCCMD", UNIPHIER_PIN_IECTRL_EXIST,
124 2, UNIPHIER_PIN_DRV_2BIT,
125 33, UNIPHIER_PIN_PULL_UP),
126 UNIPHIER_PINCTRL_PIN(34, "MMCDS", UNIPHIER_PIN_IECTRL_EXIST,
127 3, UNIPHIER_PIN_DRV_2BIT,
128 34, UNIPHIER_PIN_PULL_DOWN),
129 UNIPHIER_PINCTRL_PIN(35, "MMCDAT0", UNIPHIER_PIN_IECTRL_EXIST,
130 4, UNIPHIER_PIN_DRV_2BIT,
131 35, UNIPHIER_PIN_PULL_UP),
132 UNIPHIER_PINCTRL_PIN(36, "MMCDAT1", UNIPHIER_PIN_IECTRL_EXIST,
133 5, UNIPHIER_PIN_DRV_2BIT,
134 36, UNIPHIER_PIN_PULL_UP),
135 UNIPHIER_PINCTRL_PIN(37, "MMCDAT2", UNIPHIER_PIN_IECTRL_EXIST,
136 6, UNIPHIER_PIN_DRV_2BIT,
137 37, UNIPHIER_PIN_PULL_UP),
138 UNIPHIER_PINCTRL_PIN(38, "MMCDAT3", UNIPHIER_PIN_IECTRL_EXIST,
139 7, UNIPHIER_PIN_DRV_2BIT,
140 38, UNIPHIER_PIN_PULL_UP),
141 UNIPHIER_PINCTRL_PIN(39, "MMCDAT4", UNIPHIER_PIN_IECTRL_EXIST,
142 8, UNIPHIER_PIN_DRV_2BIT,
143 39, UNIPHIER_PIN_PULL_UP),
144 UNIPHIER_PINCTRL_PIN(40, "MMCDAT5", UNIPHIER_PIN_IECTRL_EXIST,
145 9, UNIPHIER_PIN_DRV_2BIT,
146 40, UNIPHIER_PIN_PULL_UP),
147 UNIPHIER_PINCTRL_PIN(41, "MMCDAT6", UNIPHIER_PIN_IECTRL_EXIST,
148 10, UNIPHIER_PIN_DRV_2BIT,
149 41, UNIPHIER_PIN_PULL_UP),
150 UNIPHIER_PINCTRL_PIN(42, "MMCDAT7", UNIPHIER_PIN_IECTRL_EXIST,
151 11, UNIPHIER_PIN_DRV_2BIT,
152 42, UNIPHIER_PIN_PULL_UP),
153 UNIPHIER_PINCTRL_PIN(43, "SDCLK", UNIPHIER_PIN_IECTRL_EXIST,
154 12, UNIPHIER_PIN_DRV_2BIT,
155 43, UNIPHIER_PIN_PULL_UP),
156 UNIPHIER_PINCTRL_PIN(44, "SDCMD", UNIPHIER_PIN_IECTRL_EXIST,
157 13, UNIPHIER_PIN_DRV_2BIT,
158 44, UNIPHIER_PIN_PULL_UP),
159 UNIPHIER_PINCTRL_PIN(45, "SDDAT0", UNIPHIER_PIN_IECTRL_EXIST,
160 14, UNIPHIER_PIN_DRV_2BIT,
161 45, UNIPHIER_PIN_PULL_UP),
162 UNIPHIER_PINCTRL_PIN(46, "SDDAT1", UNIPHIER_PIN_IECTRL_EXIST,
163 15, UNIPHIER_PIN_DRV_2BIT,
164 46, UNIPHIER_PIN_PULL_UP),
165 UNIPHIER_PINCTRL_PIN(47, "SDDAT2", UNIPHIER_PIN_IECTRL_EXIST,
166 16, UNIPHIER_PIN_DRV_2BIT,
167 47, UNIPHIER_PIN_PULL_UP),
168 UNIPHIER_PINCTRL_PIN(48, "SDDAT3", UNIPHIER_PIN_IECTRL_EXIST,
169 17, UNIPHIER_PIN_DRV_2BIT,
170 48, UNIPHIER_PIN_PULL_UP),
171 UNIPHIER_PINCTRL_PIN(49, "SDCD", UNIPHIER_PIN_IECTRL_EXIST,
172 31, UNIPHIER_PIN_DRV_3BIT,
173 49, UNIPHIER_PIN_PULL_UP),
174 UNIPHIER_PINCTRL_PIN(50, "SDWP", UNIPHIER_PIN_IECTRL_EXIST,
175 32, UNIPHIER_PIN_DRV_3BIT,
176 50, UNIPHIER_PIN_PULL_UP),
177 UNIPHIER_PINCTRL_PIN(51, "SDVOLC", UNIPHIER_PIN_IECTRL_EXIST,
178 33, UNIPHIER_PIN_DRV_3BIT,
179 51, UNIPHIER_PIN_PULL_UP),
180 UNIPHIER_PINCTRL_PIN(52, "MDC0", UNIPHIER_PIN_IECTRL_EXIST,
181 18, UNIPHIER_PIN_DRV_2BIT,
182 52, UNIPHIER_PIN_PULL_UP),
183 UNIPHIER_PINCTRL_PIN(53, "MDIO0", UNIPHIER_PIN_IECTRL_EXIST,
184 19, UNIPHIER_PIN_DRV_2BIT,
185 53, UNIPHIER_PIN_PULL_UP),
186 UNIPHIER_PINCTRL_PIN(54, "MDIO0_INTL", UNIPHIER_PIN_IECTRL_EXIST,
187 20, UNIPHIER_PIN_DRV_2BIT,
188 54, UNIPHIER_PIN_PULL_UP),
189 UNIPHIER_PINCTRL_PIN(55, "PHYRSTL0", UNIPHIER_PIN_IECTRL_EXIST,
190 21, UNIPHIER_PIN_DRV_2BIT,
191 55, UNIPHIER_PIN_PULL_UP),
192 UNIPHIER_PINCTRL_PIN(56, "RGMII0_RXCLK", UNIPHIER_PIN_IECTRL_EXIST,
193 22, UNIPHIER_PIN_DRV_2BIT,
194 56, UNIPHIER_PIN_PULL_UP),
195 UNIPHIER_PINCTRL_PIN(57, "RGMII0_RXD0", UNIPHIER_PIN_IECTRL_EXIST,
196 23, UNIPHIER_PIN_DRV_2BIT,
197 57, UNIPHIER_PIN_PULL_UP),
198 UNIPHIER_PINCTRL_PIN(58, "RGMII0_RXD1", UNIPHIER_PIN_IECTRL_EXIST,
199 24, UNIPHIER_PIN_DRV_2BIT,
200 58, UNIPHIER_PIN_PULL_UP),
201 UNIPHIER_PINCTRL_PIN(59, "RGMII0_RXD2", UNIPHIER_PIN_IECTRL_EXIST,
202 25, UNIPHIER_PIN_DRV_2BIT,
203 59, UNIPHIER_PIN_PULL_UP),
204 UNIPHIER_PINCTRL_PIN(60, "RGMII0_RXD3", UNIPHIER_PIN_IECTRL_EXIST,
205 26, UNIPHIER_PIN_DRV_2BIT,
206 60, UNIPHIER_PIN_PULL_UP),
207 UNIPHIER_PINCTRL_PIN(61, "RGMII0_RXCTL", UNIPHIER_PIN_IECTRL_EXIST,
208 27, UNIPHIER_PIN_DRV_2BIT,
209 61, UNIPHIER_PIN_PULL_UP),
210 UNIPHIER_PINCTRL_PIN(62, "RGMII0_TXCLK", UNIPHIER_PIN_IECTRL_EXIST,
211 28, UNIPHIER_PIN_DRV_2BIT,
212 62, UNIPHIER_PIN_PULL_DOWN),
213 UNIPHIER_PINCTRL_PIN(63, "RGMII0_TXD0", UNIPHIER_PIN_IECTRL_EXIST,
214 29, UNIPHIER_PIN_DRV_2BIT,
215 63, UNIPHIER_PIN_PULL_DOWN),
216 UNIPHIER_PINCTRL_PIN(64, "RGMII0_TXD1", UNIPHIER_PIN_IECTRL_EXIST,
217 30, UNIPHIER_PIN_DRV_2BIT,
218 64, UNIPHIER_PIN_PULL_DOWN),
219 UNIPHIER_PINCTRL_PIN(65, "RGMII0_TXD2", UNIPHIER_PIN_IECTRL_EXIST,
220 31, UNIPHIER_PIN_DRV_2BIT,
221 65, UNIPHIER_PIN_PULL_DOWN),
222 UNIPHIER_PINCTRL_PIN(66, "RGMII0_TXD3", UNIPHIER_PIN_IECTRL_EXIST,
223 32, UNIPHIER_PIN_DRV_2BIT,
224 66, UNIPHIER_PIN_PULL_DOWN),
225 UNIPHIER_PINCTRL_PIN(67, "RGMII0_TXCTL", UNIPHIER_PIN_IECTRL_EXIST,
226 33, UNIPHIER_PIN_DRV_2BIT,
227 67, UNIPHIER_PIN_PULL_DOWN),
228 UNIPHIER_PINCTRL_PIN(68, "MDC1", UNIPHIER_PIN_IECTRL_EXIST,
229 34, UNIPHIER_PIN_DRV_2BIT,
230 68, UNIPHIER_PIN_PULL_UP),
231 UNIPHIER_PINCTRL_PIN(69, "MDIO1", UNIPHIER_PIN_IECTRL_EXIST,
232 35, UNIPHIER_PIN_DRV_2BIT,
233 69, UNIPHIER_PIN_PULL_UP),
234 UNIPHIER_PINCTRL_PIN(70, "MDIO1_INTL", UNIPHIER_PIN_IECTRL_EXIST,
235 36, UNIPHIER_PIN_DRV_2BIT,
236 70, UNIPHIER_PIN_PULL_UP),
237 UNIPHIER_PINCTRL_PIN(71, "PHYRSTL1", UNIPHIER_PIN_IECTRL_EXIST,
238 37, UNIPHIER_PIN_DRV_2BIT,
239 71, UNIPHIER_PIN_PULL_UP),
240 UNIPHIER_PINCTRL_PIN(72, "RGMII1_RXCLK", UNIPHIER_PIN_IECTRL_EXIST,
241 38, UNIPHIER_PIN_DRV_2BIT,
242 72, UNIPHIER_PIN_PULL_UP),
243 UNIPHIER_PINCTRL_PIN(73, "RGMII1_RXD0", UNIPHIER_PIN_IECTRL_EXIST,
244 39, UNIPHIER_PIN_DRV_2BIT,
245 73, UNIPHIER_PIN_PULL_UP),
246 UNIPHIER_PINCTRL_PIN(74, "RGMII1_RXD1", UNIPHIER_PIN_IECTRL_EXIST,
247 40, UNIPHIER_PIN_DRV_2BIT,
248 74, UNIPHIER_PIN_PULL_UP),
249 UNIPHIER_PINCTRL_PIN(75, "RGMII1_RXD2", UNIPHIER_PIN_IECTRL_EXIST,
250 41, UNIPHIER_PIN_DRV_2BIT,
251 75, UNIPHIER_PIN_PULL_UP),
252 UNIPHIER_PINCTRL_PIN(76, "RGMII1_RXD3", UNIPHIER_PIN_IECTRL_EXIST,
253 42, UNIPHIER_PIN_DRV_2BIT,
254 76, UNIPHIER_PIN_PULL_UP),
255 UNIPHIER_PINCTRL_PIN(77, "RGMII1_RXCTL", UNIPHIER_PIN_IECTRL_EXIST,
256 43, UNIPHIER_PIN_DRV_2BIT,
257 77, UNIPHIER_PIN_PULL_UP),
258 UNIPHIER_PINCTRL_PIN(78, "RGMII1_TXCLK", UNIPHIER_PIN_IECTRL_EXIST,
259 44, UNIPHIER_PIN_DRV_2BIT,
260 78, UNIPHIER_PIN_PULL_DOWN),
261 UNIPHIER_PINCTRL_PIN(79, "RGMII1_TXD0", UNIPHIER_PIN_IECTRL_EXIST,
262 45, UNIPHIER_PIN_DRV_2BIT,
263 79, UNIPHIER_PIN_PULL_DOWN),
264 UNIPHIER_PINCTRL_PIN(80, "RGMII1_TXD1", UNIPHIER_PIN_IECTRL_EXIST,
265 46, UNIPHIER_PIN_DRV_2BIT,
266 80, UNIPHIER_PIN_PULL_DOWN),
267 UNIPHIER_PINCTRL_PIN(81, "RGMII1_TXD2", UNIPHIER_PIN_IECTRL_EXIST,
268 47, UNIPHIER_PIN_DRV_2BIT,
269 81, UNIPHIER_PIN_PULL_DOWN),
270 UNIPHIER_PINCTRL_PIN(82, "RGMII1_TXD3", UNIPHIER_PIN_IECTRL_EXIST,
271 48, UNIPHIER_PIN_DRV_2BIT,
272 82, UNIPHIER_PIN_PULL_DOWN),
273 UNIPHIER_PINCTRL_PIN(83, "RGMII1_TXCTL", UNIPHIER_PIN_IECTRL_EXIST,
274 49, UNIPHIER_PIN_DRV_2BIT,
275 83, UNIPHIER_PIN_PULL_DOWN),
276 UNIPHIER_PINCTRL_PIN(84, "USB0VBUS", UNIPHIER_PIN_IECTRL_EXIST,
277 34, UNIPHIER_PIN_DRV_3BIT,
278 84, UNIPHIER_PIN_PULL_DOWN),
279 UNIPHIER_PINCTRL_PIN(85, "USB0OD", UNIPHIER_PIN_IECTRL_EXIST,
280 35, UNIPHIER_PIN_DRV_3BIT,
281 85, UNIPHIER_PIN_PULL_UP),
282 UNIPHIER_PINCTRL_PIN(86, "USB1VBUS", UNIPHIER_PIN_IECTRL_EXIST,
283 36, UNIPHIER_PIN_DRV_3BIT,
284 86, UNIPHIER_PIN_PULL_DOWN),
285 UNIPHIER_PINCTRL_PIN(87, "USB1OD", UNIPHIER_PIN_IECTRL_EXIST,
286 37, UNIPHIER_PIN_DRV_3BIT,
287 87, UNIPHIER_PIN_PULL_UP),
288 UNIPHIER_PINCTRL_PIN(88, "USB2VBUS", UNIPHIER_PIN_IECTRL_EXIST,
289 38, UNIPHIER_PIN_DRV_3BIT,
290 88, UNIPHIER_PIN_PULL_DOWN),
291 UNIPHIER_PINCTRL_PIN(89, "USB2OD", UNIPHIER_PIN_IECTRL_EXIST,
292 39, UNIPHIER_PIN_DRV_3BIT,
293 89, UNIPHIER_PIN_PULL_UP),
294 UNIPHIER_PINCTRL_PIN(90, "USB3VBUS", UNIPHIER_PIN_IECTRL_EXIST,
295 40, UNIPHIER_PIN_DRV_3BIT,
296 90, UNIPHIER_PIN_PULL_DOWN),
297 UNIPHIER_PINCTRL_PIN(91, "USB3OD", UNIPHIER_PIN_IECTRL_EXIST,
298 41, UNIPHIER_PIN_DRV_3BIT,
299 91, UNIPHIER_PIN_PULL_UP),
300 UNIPHIER_PINCTRL_PIN(92, "TXD0", UNIPHIER_PIN_IECTRL_EXIST,
301 42, UNIPHIER_PIN_DRV_3BIT,
302 92, UNIPHIER_PIN_PULL_UP),
303 UNIPHIER_PINCTRL_PIN(93, "RXD0", UNIPHIER_PIN_IECTRL_EXIST,
304 43, UNIPHIER_PIN_DRV_3BIT,
305 93, UNIPHIER_PIN_PULL_UP),
306 UNIPHIER_PINCTRL_PIN(94, "TXD1", UNIPHIER_PIN_IECTRL_EXIST,
307 44, UNIPHIER_PIN_DRV_3BIT,
308 94, UNIPHIER_PIN_PULL_UP),
309 UNIPHIER_PINCTRL_PIN(95, "RXD1", UNIPHIER_PIN_IECTRL_EXIST,
310 45, UNIPHIER_PIN_DRV_3BIT,
311 95, UNIPHIER_PIN_PULL_UP),
312 UNIPHIER_PINCTRL_PIN(96, "TXD2", UNIPHIER_PIN_IECTRL_EXIST,
313 46, UNIPHIER_PIN_DRV_3BIT,
314 96, UNIPHIER_PIN_PULL_UP),
315 UNIPHIER_PINCTRL_PIN(97, "RXD2", UNIPHIER_PIN_IECTRL_EXIST,
316 47, UNIPHIER_PIN_DRV_3BIT,
317 97, UNIPHIER_PIN_PULL_UP),
318 UNIPHIER_PINCTRL_PIN(98, "TXD3", UNIPHIER_PIN_IECTRL_EXIST,
319 48, UNIPHIER_PIN_DRV_3BIT,
320 98, UNIPHIER_PIN_PULL_UP),
321 UNIPHIER_PINCTRL_PIN(99, "RXD3", UNIPHIER_PIN_IECTRL_EXIST,
322 49, UNIPHIER_PIN_DRV_3BIT,
323 99, UNIPHIER_PIN_PULL_UP),
324 UNIPHIER_PINCTRL_PIN(100, "SPISYNC0", UNIPHIER_PIN_IECTRL_EXIST,
325 50, UNIPHIER_PIN_DRV_3BIT,
326 100, UNIPHIER_PIN_PULL_DOWN),
327 UNIPHIER_PINCTRL_PIN(101, "SPISCLK0", UNIPHIER_PIN_IECTRL_EXIST,
328 51, UNIPHIER_PIN_DRV_3BIT,
329 101, UNIPHIER_PIN_PULL_DOWN),
330 UNIPHIER_PINCTRL_PIN(102, "SPITXD0", UNIPHIER_PIN_IECTRL_EXIST,
331 52, UNIPHIER_PIN_DRV_3BIT,
332 102, UNIPHIER_PIN_PULL_DOWN),
333 UNIPHIER_PINCTRL_PIN(103, "SPIRXD0", UNIPHIER_PIN_IECTRL_EXIST,
334 53, UNIPHIER_PIN_DRV_3BIT,
335 103, UNIPHIER_PIN_PULL_DOWN),
336 UNIPHIER_PINCTRL_PIN(104, "SDA0", UNIPHIER_PIN_IECTRL_EXIST,
337 -1, UNIPHIER_PIN_DRV_FIXED4,
338 -1, UNIPHIER_PIN_PULL_NONE),
339 UNIPHIER_PINCTRL_PIN(105, "SCL0", UNIPHIER_PIN_IECTRL_EXIST,
340 -1, UNIPHIER_PIN_DRV_FIXED4,
341 -1, UNIPHIER_PIN_PULL_NONE),
342 UNIPHIER_PINCTRL_PIN(106, "SDA1", UNIPHIER_PIN_IECTRL_EXIST,
343 -1, UNIPHIER_PIN_DRV_FIXED4,
344 -1, UNIPHIER_PIN_PULL_NONE),
345 UNIPHIER_PINCTRL_PIN(107, "SCL1", UNIPHIER_PIN_IECTRL_EXIST,
346 -1, UNIPHIER_PIN_DRV_FIXED4,
347 -1, UNIPHIER_PIN_PULL_NONE),
348 UNIPHIER_PINCTRL_PIN(108, "SDA2", UNIPHIER_PIN_IECTRL_EXIST,
349 -1, UNIPHIER_PIN_DRV_FIXED4,
350 -1, UNIPHIER_PIN_PULL_NONE),
351 UNIPHIER_PINCTRL_PIN(109, "SCL2", UNIPHIER_PIN_IECTRL_EXIST,
352 -1, UNIPHIER_PIN_DRV_FIXED4,
353 -1, UNIPHIER_PIN_PULL_NONE),
354 UNIPHIER_PINCTRL_PIN(110, "SDA3", UNIPHIER_PIN_IECTRL_EXIST,
355 -1, UNIPHIER_PIN_DRV_FIXED4,
356 -1, UNIPHIER_PIN_PULL_NONE),
357 UNIPHIER_PINCTRL_PIN(111, "SCL3", UNIPHIER_PIN_IECTRL_EXIST,
358 -1, UNIPHIER_PIN_DRV_FIXED4,
359 -1, UNIPHIER_PIN_PULL_NONE),
360 UNIPHIER_PINCTRL_PIN(112, "SMTRST0", UNIPHIER_PIN_IECTRL_EXIST,
361 54, UNIPHIER_PIN_DRV_3BIT,
362 112, UNIPHIER_PIN_PULL_DOWN),
363 UNIPHIER_PINCTRL_PIN(113, "SMTCMD0", UNIPHIER_PIN_IECTRL_EXIST,
364 55, UNIPHIER_PIN_DRV_3BIT,
365 113, UNIPHIER_PIN_PULL_DOWN),
366 UNIPHIER_PINCTRL_PIN(114, "SMTD0", UNIPHIER_PIN_IECTRL_EXIST,
367 56, UNIPHIER_PIN_DRV_3BIT,
368 114, UNIPHIER_PIN_PULL_DOWN),
369 UNIPHIER_PINCTRL_PIN(115, "SMTSEL0", UNIPHIER_PIN_IECTRL_EXIST,
370 57, UNIPHIER_PIN_DRV_3BIT,
371 115, UNIPHIER_PIN_PULL_DOWN),
372 UNIPHIER_PINCTRL_PIN(116, "SMTCLK0CG", UNIPHIER_PIN_IECTRL_EXIST,
373 58, UNIPHIER_PIN_DRV_3BIT,
374 116, UNIPHIER_PIN_PULL_DOWN),
375 UNIPHIER_PINCTRL_PIN(117, "SMTDET0", UNIPHIER_PIN_IECTRL_EXIST,
376 59, UNIPHIER_PIN_DRV_3BIT,
377 117, UNIPHIER_PIN_PULL_DOWN),
378 UNIPHIER_PINCTRL_PIN(118, "SMTRST1", UNIPHIER_PIN_IECTRL_EXIST,
379 60, UNIPHIER_PIN_DRV_3BIT,
380 118, UNIPHIER_PIN_PULL_DOWN),
381 UNIPHIER_PINCTRL_PIN(119, "SMTCMD1", UNIPHIER_PIN_IECTRL_EXIST,
382 61, UNIPHIER_PIN_DRV_3BIT,
383 119, UNIPHIER_PIN_PULL_DOWN),
384 UNIPHIER_PINCTRL_PIN(120, "SMTD1", UNIPHIER_PIN_IECTRL_EXIST,
385 62, UNIPHIER_PIN_DRV_3BIT,
386 120, UNIPHIER_PIN_PULL_DOWN),
387 UNIPHIER_PINCTRL_PIN(121, "SMTSEL1", UNIPHIER_PIN_IECTRL_EXIST,
388 63, UNIPHIER_PIN_DRV_3BIT,
389 121, UNIPHIER_PIN_PULL_DOWN),
390 UNIPHIER_PINCTRL_PIN(122, "SMTCLK1CG", UNIPHIER_PIN_IECTRL_EXIST,
391 64, UNIPHIER_PIN_DRV_3BIT,
392 122, UNIPHIER_PIN_PULL_DOWN),
393 UNIPHIER_PINCTRL_PIN(123, "SMTDET1", UNIPHIER_PIN_IECTRL_EXIST,
394 65, UNIPHIER_PIN_DRV_3BIT,
395 123, UNIPHIER_PIN_PULL_DOWN),
396 UNIPHIER_PINCTRL_PIN(124, "SMTRST2", UNIPHIER_PIN_IECTRL_EXIST,
397 66, UNIPHIER_PIN_DRV_3BIT,
398 124, UNIPHIER_PIN_PULL_DOWN),
399 UNIPHIER_PINCTRL_PIN(125, "SMTCMD2", UNIPHIER_PIN_IECTRL_EXIST,
400 67, UNIPHIER_PIN_DRV_3BIT,
401 125, UNIPHIER_PIN_PULL_DOWN),
402 UNIPHIER_PINCTRL_PIN(126, "SMTD2", UNIPHIER_PIN_IECTRL_EXIST,
403 68, UNIPHIER_PIN_DRV_3BIT,
404 126, UNIPHIER_PIN_PULL_DOWN),
405 UNIPHIER_PINCTRL_PIN(127, "SMTSEL2", UNIPHIER_PIN_IECTRL_EXIST,
406 69, UNIPHIER_PIN_DRV_3BIT,
407 127, UNIPHIER_PIN_PULL_DOWN),
408 UNIPHIER_PINCTRL_PIN(128, "SMTCLK2CG", UNIPHIER_PIN_IECTRL_EXIST,
409 70, UNIPHIER_PIN_DRV_3BIT,
410 128, UNIPHIER_PIN_PULL_DOWN),
411 UNIPHIER_PINCTRL_PIN(129, "SMTDET2", UNIPHIER_PIN_IECTRL_EXIST,
412 71, UNIPHIER_PIN_DRV_3BIT,
413 129, UNIPHIER_PIN_PULL_DOWN),
414 UNIPHIER_PINCTRL_PIN(130, "CH0CLK", UNIPHIER_PIN_IECTRL_EXIST,
415 72, UNIPHIER_PIN_DRV_3BIT,
416 130, UNIPHIER_PIN_PULL_DOWN),
417 UNIPHIER_PINCTRL_PIN(131, "CH0PSYNC", UNIPHIER_PIN_IECTRL_EXIST,
418 73, UNIPHIER_PIN_DRV_3BIT,
419 131, UNIPHIER_PIN_PULL_DOWN),
420 UNIPHIER_PINCTRL_PIN(132, "CH0VAL", UNIPHIER_PIN_IECTRL_EXIST,
421 74, UNIPHIER_PIN_DRV_3BIT,
422 132, UNIPHIER_PIN_PULL_DOWN),
423 UNIPHIER_PINCTRL_PIN(133, "CH0DATA", UNIPHIER_PIN_IECTRL_EXIST,
424 75, UNIPHIER_PIN_DRV_3BIT,
425 133, UNIPHIER_PIN_PULL_DOWN),
426 UNIPHIER_PINCTRL_PIN(134, "CH1CLK", UNIPHIER_PIN_IECTRL_EXIST,
427 76, UNIPHIER_PIN_DRV_3BIT,
428 134, UNIPHIER_PIN_PULL_DOWN),
429 UNIPHIER_PINCTRL_PIN(135, "CH1PSYNC", UNIPHIER_PIN_IECTRL_EXIST,
430 77, UNIPHIER_PIN_DRV_3BIT,
431 135, UNIPHIER_PIN_PULL_DOWN),
432 UNIPHIER_PINCTRL_PIN(136, "CH1VAL", UNIPHIER_PIN_IECTRL_EXIST,
433 78, UNIPHIER_PIN_DRV_3BIT,
434 136, UNIPHIER_PIN_PULL_DOWN),
435 UNIPHIER_PINCTRL_PIN(137, "CH1DATA", UNIPHIER_PIN_IECTRL_EXIST,
436 79, UNIPHIER_PIN_DRV_3BIT,
437 137, UNIPHIER_PIN_PULL_DOWN),
438 UNIPHIER_PINCTRL_PIN(138, "CH2CLK", UNIPHIER_PIN_IECTRL_EXIST,
439 80, UNIPHIER_PIN_DRV_3BIT,
440 138, UNIPHIER_PIN_PULL_DOWN),
441 UNIPHIER_PINCTRL_PIN(139, "CH2PSYNC", UNIPHIER_PIN_IECTRL_EXIST,
442 81, UNIPHIER_PIN_DRV_3BIT,
443 139, UNIPHIER_PIN_PULL_DOWN),
444 UNIPHIER_PINCTRL_PIN(140, "CH2VAL", UNIPHIER_PIN_IECTRL_EXIST,
445 82, UNIPHIER_PIN_DRV_3BIT,
446 140, UNIPHIER_PIN_PULL_DOWN),
447 UNIPHIER_PINCTRL_PIN(141, "CH2DATA", UNIPHIER_PIN_IECTRL_EXIST,
448 83, UNIPHIER_PIN_DRV_3BIT,
449 141, UNIPHIER_PIN_PULL_DOWN),
450 UNIPHIER_PINCTRL_PIN(142, "HS0BCLKIN", UNIPHIER_PIN_IECTRL_EXIST,
451 84, UNIPHIER_PIN_DRV_3BIT,
452 142, UNIPHIER_PIN_PULL_DOWN),
453 UNIPHIER_PINCTRL_PIN(143, "HS0SYNCIN", UNIPHIER_PIN_IECTRL_EXIST,
454 85, UNIPHIER_PIN_DRV_3BIT,
455 143, UNIPHIER_PIN_PULL_DOWN),
456 UNIPHIER_PINCTRL_PIN(144, "HS0VALIN", UNIPHIER_PIN_IECTRL_EXIST,
457 86, UNIPHIER_PIN_DRV_3BIT,
458 144, UNIPHIER_PIN_PULL_DOWN),
459 UNIPHIER_PINCTRL_PIN(145, "HS0DIN0", UNIPHIER_PIN_IECTRL_EXIST,
460 87, UNIPHIER_PIN_DRV_3BIT,
461 145, UNIPHIER_PIN_PULL_DOWN),
462 UNIPHIER_PINCTRL_PIN(146, "HS0DIN1", UNIPHIER_PIN_IECTRL_EXIST,
463 88, UNIPHIER_PIN_DRV_3BIT,
464 146, UNIPHIER_PIN_PULL_DOWN),
465 UNIPHIER_PINCTRL_PIN(147, "HS0DIN2", UNIPHIER_PIN_IECTRL_EXIST,
466 89, UNIPHIER_PIN_DRV_3BIT,
467 147, UNIPHIER_PIN_PULL_DOWN),
468 UNIPHIER_PINCTRL_PIN(148, "HS0DIN3", UNIPHIER_PIN_IECTRL_EXIST,
469 90, UNIPHIER_PIN_DRV_3BIT,
470 148, UNIPHIER_PIN_PULL_DOWN),
471 UNIPHIER_PINCTRL_PIN(149, "HS0DIN4", UNIPHIER_PIN_IECTRL_EXIST,
472 91, UNIPHIER_PIN_DRV_3BIT,
473 149, UNIPHIER_PIN_PULL_DOWN),
474 UNIPHIER_PINCTRL_PIN(150, "HS0DIN5", UNIPHIER_PIN_IECTRL_EXIST,
475 92, UNIPHIER_PIN_DRV_3BIT,
476 150, UNIPHIER_PIN_PULL_DOWN),
477 UNIPHIER_PINCTRL_PIN(151, "HS0DIN6", UNIPHIER_PIN_IECTRL_EXIST,
478 93, UNIPHIER_PIN_DRV_3BIT,
479 151, UNIPHIER_PIN_PULL_DOWN),
480 UNIPHIER_PINCTRL_PIN(152, "HS0DIN7", UNIPHIER_PIN_IECTRL_EXIST,
481 94, UNIPHIER_PIN_DRV_3BIT,
482 152, UNIPHIER_PIN_PULL_DOWN),
483 UNIPHIER_PINCTRL_PIN(153, "HS1BCLKIN", UNIPHIER_PIN_IECTRL_EXIST,
484 95, UNIPHIER_PIN_DRV_3BIT,
485 153, UNIPHIER_PIN_PULL_DOWN),
486 UNIPHIER_PINCTRL_PIN(154, "HS1SYNCIN", UNIPHIER_PIN_IECTRL_EXIST,
487 96, UNIPHIER_PIN_DRV_3BIT,
488 154, UNIPHIER_PIN_PULL_DOWN),
489 UNIPHIER_PINCTRL_PIN(155, "HS1VALIN", UNIPHIER_PIN_IECTRL_EXIST,
490 97, UNIPHIER_PIN_DRV_3BIT,
491 155, UNIPHIER_PIN_PULL_DOWN),
492 UNIPHIER_PINCTRL_PIN(156, "HS1DIN0", UNIPHIER_PIN_IECTRL_EXIST,
493 98, UNIPHIER_PIN_DRV_3BIT,
494 156, UNIPHIER_PIN_PULL_DOWN),
495 UNIPHIER_PINCTRL_PIN(157, "HS1DIN1", UNIPHIER_PIN_IECTRL_EXIST,
496 99, UNIPHIER_PIN_DRV_3BIT,
497 157, UNIPHIER_PIN_PULL_DOWN),
498 UNIPHIER_PINCTRL_PIN(158, "HS1DIN2", UNIPHIER_PIN_IECTRL_EXIST,
499 100, UNIPHIER_PIN_DRV_3BIT,
500 158, UNIPHIER_PIN_PULL_DOWN),
501 UNIPHIER_PINCTRL_PIN(159, "HS1DIN3", UNIPHIER_PIN_IECTRL_EXIST,
502 101, UNIPHIER_PIN_DRV_3BIT,
503 159, UNIPHIER_PIN_PULL_DOWN),
504 UNIPHIER_PINCTRL_PIN(160, "HS1DIN4", UNIPHIER_PIN_IECTRL_EXIST,
505 102, UNIPHIER_PIN_DRV_3BIT,
506 160, UNIPHIER_PIN_PULL_DOWN),
507 UNIPHIER_PINCTRL_PIN(161, "HS1DIN5", UNIPHIER_PIN_IECTRL_EXIST,
508 103, UNIPHIER_PIN_DRV_3BIT,
509 161, UNIPHIER_PIN_PULL_DOWN),
510 UNIPHIER_PINCTRL_PIN(162, "HS1DIN6", UNIPHIER_PIN_IECTRL_EXIST,
511 104, UNIPHIER_PIN_DRV_3BIT,
512 162, UNIPHIER_PIN_PULL_DOWN),
513 UNIPHIER_PINCTRL_PIN(163, "HS1DIN7", UNIPHIER_PIN_IECTRL_EXIST,
514 105, UNIPHIER_PIN_DRV_3BIT,
515 163, UNIPHIER_PIN_PULL_DOWN),
516 UNIPHIER_PINCTRL_PIN(164, "LINKCLK", UNIPHIER_PIN_IECTRL_EXIST,
517 106, UNIPHIER_PIN_DRV_3BIT,
518 164, UNIPHIER_PIN_PULL_DOWN),
519 UNIPHIER_PINCTRL_PIN(165, "LINKREQ", UNIPHIER_PIN_IECTRL_EXIST,
520 107, UNIPHIER_PIN_DRV_3BIT,
521 165, UNIPHIER_PIN_PULL_DOWN),
522 UNIPHIER_PINCTRL_PIN(166, "LINKCTL0", UNIPHIER_PIN_IECTRL_EXIST,
523 108, UNIPHIER_PIN_DRV_3BIT,
524 166, UNIPHIER_PIN_PULL_DOWN),
525 UNIPHIER_PINCTRL_PIN(167, "LINKCTL1", UNIPHIER_PIN_IECTRL_EXIST,
526 109, UNIPHIER_PIN_DRV_3BIT,
527 167, UNIPHIER_PIN_PULL_DOWN),
528 UNIPHIER_PINCTRL_PIN(168, "LINKDT0", UNIPHIER_PIN_IECTRL_EXIST,
529 110, UNIPHIER_PIN_DRV_3BIT,
530 168, UNIPHIER_PIN_PULL_DOWN),
531 UNIPHIER_PINCTRL_PIN(169, "LINKDT1", UNIPHIER_PIN_IECTRL_EXIST,
532 111, UNIPHIER_PIN_DRV_3BIT,
533 169, UNIPHIER_PIN_PULL_DOWN),
534 UNIPHIER_PINCTRL_PIN(170, "LINKDT2", UNIPHIER_PIN_IECTRL_EXIST,
535 112, UNIPHIER_PIN_DRV_3BIT,
536 170, UNIPHIER_PIN_PULL_DOWN),
537 UNIPHIER_PINCTRL_PIN(171, "LINKDT3", UNIPHIER_PIN_IECTRL_EXIST,
538 113, UNIPHIER_PIN_DRV_3BIT,
539 171, UNIPHIER_PIN_PULL_DOWN),
540 UNIPHIER_PINCTRL_PIN(172, "LINKDT4", UNIPHIER_PIN_IECTRL_EXIST,
541 114, UNIPHIER_PIN_DRV_3BIT,
542 172, UNIPHIER_PIN_PULL_DOWN),
543 UNIPHIER_PINCTRL_PIN(173, "LINKDT5", UNIPHIER_PIN_IECTRL_EXIST,
544 115, UNIPHIER_PIN_DRV_3BIT,
545 173, UNIPHIER_PIN_PULL_DOWN),
546 UNIPHIER_PINCTRL_PIN(174, "LINKDT6", UNIPHIER_PIN_IECTRL_EXIST,
547 116, UNIPHIER_PIN_DRV_3BIT,
548 174, UNIPHIER_PIN_PULL_DOWN),
549 UNIPHIER_PINCTRL_PIN(175, "LINKDT7", UNIPHIER_PIN_IECTRL_EXIST,
550 117, UNIPHIER_PIN_DRV_3BIT,
551 175, UNIPHIER_PIN_PULL_DOWN),
552 UNIPHIER_PINCTRL_PIN(176, "H0RXDDCSDA", UNIPHIER_PIN_IECTRL_EXIST,
553 -1, UNIPHIER_PIN_DRV_FIXED4,
554 -1, UNIPHIER_PIN_PULL_NONE),
555 UNIPHIER_PINCTRL_PIN(177, "H0RXDDCSCL", UNIPHIER_PIN_IECTRL_EXIST,
556 -1, UNIPHIER_PIN_DRV_FIXED4,
557 -1, UNIPHIER_PIN_PULL_NONE),
558 UNIPHIER_PINCTRL_PIN(178, "H0RXHPDO", UNIPHIER_PIN_IECTRL_EXIST,
559 -1, UNIPHIER_PIN_DRV_FIXED4,
560 -1, UNIPHIER_PIN_PULL_NONE),
561 UNIPHIER_PINCTRL_PIN(179, "H0RX5VDETI", UNIPHIER_PIN_IECTRL_EXIST,
562 -1, UNIPHIER_PIN_DRV_FIXED4,
563 -1, UNIPHIER_PIN_PULL_NONE),
564 UNIPHIER_PINCTRL_PIN(180, "H0TXDDCSDA", UNIPHIER_PIN_IECTRL_EXIST,
565 -1, UNIPHIER_PIN_DRV_FIXED4,
566 -1, UNIPHIER_PIN_PULL_NONE),
567 UNIPHIER_PINCTRL_PIN(181, "H0TXDDCSCL", UNIPHIER_PIN_IECTRL_EXIST,
568 -1, UNIPHIER_PIN_DRV_FIXED4,
569 -1, UNIPHIER_PIN_PULL_NONE),
570 UNIPHIER_PINCTRL_PIN(182, "H0TXHPDI", UNIPHIER_PIN_IECTRL_EXIST,
571 -1, UNIPHIER_PIN_DRV_FIXED4,
572 -1, UNIPHIER_PIN_PULL_NONE),
573 UNIPHIER_PINCTRL_PIN(183, "H1TXDDCSDA", UNIPHIER_PIN_IECTRL_EXIST,
574 -1, UNIPHIER_PIN_DRV_FIXED4,
575 -1, UNIPHIER_PIN_PULL_NONE),
576 UNIPHIER_PINCTRL_PIN(184, "H1TXDDCSCL", UNIPHIER_PIN_IECTRL_EXIST,
577 -1, UNIPHIER_PIN_DRV_FIXED4,
578 -1, UNIPHIER_PIN_PULL_NONE),
579 UNIPHIER_PINCTRL_PIN(185, "H1TXHPDI", UNIPHIER_PIN_IECTRL_EXIST,
580 -1, UNIPHIER_PIN_DRV_FIXED4,
581 -1, UNIPHIER_PIN_PULL_NONE),
582 UNIPHIER_PINCTRL_PIN(186, "AI1ADCCK", UNIPHIER_PIN_IECTRL_EXIST,
583 118, UNIPHIER_PIN_DRV_3BIT,
584 186, UNIPHIER_PIN_PULL_DOWN),
585 UNIPHIER_PINCTRL_PIN(187, "AI1BCK", UNIPHIER_PIN_IECTRL_EXIST,
586 119, UNIPHIER_PIN_DRV_3BIT,
587 187, UNIPHIER_PIN_PULL_DOWN),
588 UNIPHIER_PINCTRL_PIN(188, "AI1LRCK", UNIPHIER_PIN_IECTRL_EXIST,
589 120, UNIPHIER_PIN_DRV_3BIT,
590 188, UNIPHIER_PIN_PULL_DOWN),
591 UNIPHIER_PINCTRL_PIN(189, "AI1D0", UNIPHIER_PIN_IECTRL_EXIST,
592 121, UNIPHIER_PIN_DRV_3BIT,
593 189, UNIPHIER_PIN_PULL_DOWN),
594 UNIPHIER_PINCTRL_PIN(190, "AO1IEC", UNIPHIER_PIN_IECTRL_EXIST,
595 122, UNIPHIER_PIN_DRV_3BIT,
596 190, UNIPHIER_PIN_PULL_DOWN),
597 UNIPHIER_PINCTRL_PIN(191, "AO2IEC", UNIPHIER_PIN_IECTRL_EXIST,
598 123, UNIPHIER_PIN_DRV_3BIT,
599 191, UNIPHIER_PIN_PULL_DOWN),
600 UNIPHIER_PINCTRL_PIN(192, "AO2DACCK", UNIPHIER_PIN_IECTRL_EXIST,
601 124, UNIPHIER_PIN_DRV_3BIT,
602 192, UNIPHIER_PIN_PULL_DOWN),
603 UNIPHIER_PINCTRL_PIN(193, "AO2BCK", UNIPHIER_PIN_IECTRL_EXIST,
604 125, UNIPHIER_PIN_DRV_3BIT,
605 193, UNIPHIER_PIN_PULL_DOWN),
606 UNIPHIER_PINCTRL_PIN(194, "AO2LRCK", UNIPHIER_PIN_IECTRL_EXIST,
607 126, UNIPHIER_PIN_DRV_3BIT,
608 194, UNIPHIER_PIN_PULL_DOWN),
609 UNIPHIER_PINCTRL_PIN(195, "AO2D0", UNIPHIER_PIN_IECTRL_EXIST,
610 127, UNIPHIER_PIN_DRV_3BIT,
611 195, UNIPHIER_PIN_PULL_DOWN),
612 UNIPHIER_PINCTRL_PIN(196, "AO2D1", UNIPHIER_PIN_IECTRL_EXIST,
613 128, UNIPHIER_PIN_DRV_3BIT,
614 196, UNIPHIER_PIN_PULL_DOWN),
615 UNIPHIER_PINCTRL_PIN(197, "AO2D2", UNIPHIER_PIN_IECTRL_EXIST,
616 129, UNIPHIER_PIN_DRV_3BIT,
617 197, UNIPHIER_PIN_PULL_DOWN),
618 UNIPHIER_PINCTRL_PIN(198, "AO2D3", UNIPHIER_PIN_IECTRL_EXIST,
619 130, UNIPHIER_PIN_DRV_3BIT,
620 198, UNIPHIER_PIN_PULL_DOWN),
621 UNIPHIER_PINCTRL_PIN(199, "AO3DACCK", UNIPHIER_PIN_IECTRL_EXIST,
622 131, UNIPHIER_PIN_DRV_3BIT,
623 199, UNIPHIER_PIN_PULL_DOWN),
624 UNIPHIER_PINCTRL_PIN(200, "AO3BCK", UNIPHIER_PIN_IECTRL_EXIST,
625 132, UNIPHIER_PIN_DRV_3BIT,
626 200, UNIPHIER_PIN_PULL_DOWN),
627 UNIPHIER_PINCTRL_PIN(201, "AO3LRCK", UNIPHIER_PIN_IECTRL_EXIST,
628 133, UNIPHIER_PIN_DRV_3BIT,
629 201, UNIPHIER_PIN_PULL_DOWN),
630 UNIPHIER_PINCTRL_PIN(202, "AO3D0", UNIPHIER_PIN_IECTRL_EXIST,
631 134, UNIPHIER_PIN_DRV_3BIT,
632 202, UNIPHIER_PIN_PULL_DOWN),
633 UNIPHIER_PINCTRL_PIN(203, "VI1CLK", UNIPHIER_PIN_IECTRL_EXIST,
634 135, UNIPHIER_PIN_DRV_3BIT,
635 203, UNIPHIER_PIN_PULL_DOWN),
636 UNIPHIER_PINCTRL_PIN(204, "VI1G2", UNIPHIER_PIN_IECTRL_EXIST,
637 136, UNIPHIER_PIN_DRV_3BIT,
638 204, UNIPHIER_PIN_PULL_DOWN),
639 UNIPHIER_PINCTRL_PIN(205, "VI1G3", UNIPHIER_PIN_IECTRL_EXIST,
640 137, UNIPHIER_PIN_DRV_3BIT,
641 205, UNIPHIER_PIN_PULL_DOWN),
642 UNIPHIER_PINCTRL_PIN(206, "VI1G4", UNIPHIER_PIN_IECTRL_EXIST,
643 138, UNIPHIER_PIN_DRV_3BIT,
644 206, UNIPHIER_PIN_PULL_DOWN),
645 UNIPHIER_PINCTRL_PIN(207, "VI1G5", UNIPHIER_PIN_IECTRL_EXIST,
646 139, UNIPHIER_PIN_DRV_3BIT,
647 207, UNIPHIER_PIN_PULL_DOWN),
648 UNIPHIER_PINCTRL_PIN(208, "VI1G6", UNIPHIER_PIN_IECTRL_EXIST,
649 140, UNIPHIER_PIN_DRV_3BIT,
650 208, UNIPHIER_PIN_PULL_DOWN),
651 UNIPHIER_PINCTRL_PIN(209, "VI1G7", UNIPHIER_PIN_IECTRL_EXIST,
652 141, UNIPHIER_PIN_DRV_3BIT,
653 209, UNIPHIER_PIN_PULL_DOWN),
654 UNIPHIER_PINCTRL_PIN(210, "VI1G8", UNIPHIER_PIN_IECTRL_EXIST,
655 142, UNIPHIER_PIN_DRV_3BIT,
656 210, UNIPHIER_PIN_PULL_DOWN),
657 UNIPHIER_PINCTRL_PIN(211, "VI1G9", UNIPHIER_PIN_IECTRL_EXIST,
658 143, UNIPHIER_PIN_DRV_3BIT,
659 211, UNIPHIER_PIN_PULL_DOWN),
660 UNIPHIER_PINCTRL_PIN(212, "FANPWM", UNIPHIER_PIN_IECTRL_EXIST,
661 144, UNIPHIER_PIN_DRV_3BIT,
662 212, UNIPHIER_PIN_PULL_DOWN),
663 UNIPHIER_PINCTRL_PIN(213, "CK27EXO", UNIPHIER_PIN_IECTRL_EXIST,
664 145, UNIPHIER_PIN_DRV_3BIT,
665 213, UNIPHIER_PIN_PULL_DOWN),
666 UNIPHIER_PINCTRL_PIN(214, "CK27AO", UNIPHIER_PIN_IECTRL_EXIST,
667 146, UNIPHIER_PIN_DRV_3BIT,
668 214, UNIPHIER_PIN_PULL_DOWN),
669 UNIPHIER_PINCTRL_PIN(215, "CK27EXI", UNIPHIER_PIN_IECTRL_EXIST,
670 147, UNIPHIER_PIN_DRV_3BIT,
671 215, UNIPHIER_PIN_PULL_DOWN),
672 UNIPHIER_PINCTRL_PIN(216, "VEXCKA", UNIPHIER_PIN_IECTRL_EXIST,
673 148, UNIPHIER_PIN_DRV_3BIT,
674 216, UNIPHIER_PIN_PULL_DOWN),
675 UNIPHIER_PINCTRL_PIN(217, "AEXCKA", UNIPHIER_PIN_IECTRL_EXIST,
676 149, UNIPHIER_PIN_DRV_3BIT,
677 217, UNIPHIER_PIN_PULL_DOWN),
678 UNIPHIER_PINCTRL_PIN(218, "ASEL", UNIPHIER_PIN_IECTRL_EXIST,
679 150, UNIPHIER_PIN_DRV_3BIT,
680 218, UNIPHIER_PIN_PULL_DOWN),
681 UNIPHIER_PINCTRL_PIN(219, "XIRQ0", UNIPHIER_PIN_IECTRL_EXIST,
682 151, UNIPHIER_PIN_DRV_3BIT,
683 219, UNIPHIER_PIN_PULL_DOWN),
684 UNIPHIER_PINCTRL_PIN(220, "XIRQ1", UNIPHIER_PIN_IECTRL_EXIST,
685 152, UNIPHIER_PIN_DRV_3BIT,
686 220, UNIPHIER_PIN_PULL_DOWN),
687 UNIPHIER_PINCTRL_PIN(221, "XIRQ2", UNIPHIER_PIN_IECTRL_EXIST,
688 153, UNIPHIER_PIN_DRV_3BIT,
689 221, UNIPHIER_PIN_PULL_DOWN),
690 UNIPHIER_PINCTRL_PIN(222, "XIRQ3", UNIPHIER_PIN_IECTRL_EXIST,
691 154, UNIPHIER_PIN_DRV_3BIT,
692 222, UNIPHIER_PIN_PULL_DOWN),
693 UNIPHIER_PINCTRL_PIN(223, "XIRQ4", UNIPHIER_PIN_IECTRL_EXIST,
694 155, UNIPHIER_PIN_DRV_3BIT,
695 223, UNIPHIER_PIN_PULL_DOWN),
696 UNIPHIER_PINCTRL_PIN(224, "XIRQ5", UNIPHIER_PIN_IECTRL_EXIST,
697 156, UNIPHIER_PIN_DRV_3BIT,
698 224, UNIPHIER_PIN_PULL_DOWN),
699 UNIPHIER_PINCTRL_PIN(225, "XIRQ6", UNIPHIER_PIN_IECTRL_EXIST,
700 157, UNIPHIER_PIN_DRV_3BIT,
701 225, UNIPHIER_PIN_PULL_DOWN),
702 UNIPHIER_PINCTRL_PIN(226, "XIRQ7", UNIPHIER_PIN_IECTRL_EXIST,
703 158, UNIPHIER_PIN_DRV_3BIT,
704 226, UNIPHIER_PIN_PULL_DOWN),
705 UNIPHIER_PINCTRL_PIN(227, "XIRQ8", UNIPHIER_PIN_IECTRL_EXIST,
706 159, UNIPHIER_PIN_DRV_3BIT,
707 227, UNIPHIER_PIN_PULL_DOWN),
708 UNIPHIER_PINCTRL_PIN(228, "XIRQ9", UNIPHIER_PIN_IECTRL_EXIST,
709 160, UNIPHIER_PIN_DRV_3BIT,
710 228, UNIPHIER_PIN_PULL_DOWN),
711 UNIPHIER_PINCTRL_PIN(229, "XIRQ10", UNIPHIER_PIN_IECTRL_EXIST,
712 161, UNIPHIER_PIN_DRV_3BIT,
713 229, UNIPHIER_PIN_PULL_DOWN),
714 UNIPHIER_PINCTRL_PIN(230, "XIRQ11", UNIPHIER_PIN_IECTRL_EXIST,
715 162, UNIPHIER_PIN_DRV_3BIT,
716 230, UNIPHIER_PIN_PULL_DOWN),
717 UNIPHIER_PINCTRL_PIN(231, "XIRQ12", UNIPHIER_PIN_IECTRL_EXIST,
718 163, UNIPHIER_PIN_DRV_3BIT,
719 231, UNIPHIER_PIN_PULL_DOWN),
720 UNIPHIER_PINCTRL_PIN(232, "XIRQ13", UNIPHIER_PIN_IECTRL_EXIST,
721 164, UNIPHIER_PIN_DRV_3BIT,
722 232, UNIPHIER_PIN_PULL_DOWN),
723 UNIPHIER_PINCTRL_PIN(233, "XIRQ14", UNIPHIER_PIN_IECTRL_EXIST,
724 165, UNIPHIER_PIN_DRV_3BIT,
725 233, UNIPHIER_PIN_PULL_DOWN),
726 UNIPHIER_PINCTRL_PIN(234, "XIRQ15", UNIPHIER_PIN_IECTRL_EXIST,
727 166, UNIPHIER_PIN_DRV_3BIT,
728 234, UNIPHIER_PIN_PULL_DOWN),
729 UNIPHIER_PINCTRL_PIN(235, "PORT00", UNIPHIER_PIN_IECTRL_EXIST,
730 167, UNIPHIER_PIN_DRV_3BIT,
731 235, UNIPHIER_PIN_PULL_DOWN),
732 UNIPHIER_PINCTRL_PIN(236, "PORT01", UNIPHIER_PIN_IECTRL_EXIST,
733 168, UNIPHIER_PIN_DRV_3BIT,
734 236, UNIPHIER_PIN_PULL_DOWN),
735 UNIPHIER_PINCTRL_PIN(237, "PORT02", UNIPHIER_PIN_IECTRL_EXIST,
736 169, UNIPHIER_PIN_DRV_3BIT,
737 237, UNIPHIER_PIN_PULL_DOWN),
738 UNIPHIER_PINCTRL_PIN(238, "PORT03", UNIPHIER_PIN_IECTRL_EXIST,
739 170, UNIPHIER_PIN_DRV_3BIT,
740 238, UNIPHIER_PIN_PULL_DOWN),
741 UNIPHIER_PINCTRL_PIN(239, "PORT04", UNIPHIER_PIN_IECTRL_EXIST,
742 171, UNIPHIER_PIN_DRV_3BIT,
743 239, UNIPHIER_PIN_PULL_DOWN),
744 UNIPHIER_PINCTRL_PIN(240, "PORT05", UNIPHIER_PIN_IECTRL_EXIST,
745 172, UNIPHIER_PIN_DRV_3BIT,
746 240, UNIPHIER_PIN_PULL_DOWN),
747 UNIPHIER_PINCTRL_PIN(241, "PORT06", UNIPHIER_PIN_IECTRL_EXIST,
748 173, UNIPHIER_PIN_DRV_3BIT,
749 241, UNIPHIER_PIN_PULL_DOWN),
750 UNIPHIER_PINCTRL_PIN(242, "PORT07", UNIPHIER_PIN_IECTRL_EXIST,
751 174, UNIPHIER_PIN_DRV_3BIT,
752 242, UNIPHIER_PIN_PULL_DOWN),
753 UNIPHIER_PINCTRL_PIN(243, "PORT10", UNIPHIER_PIN_IECTRL_EXIST,
754 175, UNIPHIER_PIN_DRV_3BIT,
755 243, UNIPHIER_PIN_PULL_DOWN),
756 UNIPHIER_PINCTRL_PIN(244, "PORT11", UNIPHIER_PIN_IECTRL_EXIST,
757 176, UNIPHIER_PIN_DRV_3BIT,
758 244, UNIPHIER_PIN_PULL_DOWN),
759 UNIPHIER_PINCTRL_PIN(245, "PORT12", UNIPHIER_PIN_IECTRL_EXIST,
760 177, UNIPHIER_PIN_DRV_3BIT,
761 245, UNIPHIER_PIN_PULL_DOWN),
762 UNIPHIER_PINCTRL_PIN(246, "PORT13", UNIPHIER_PIN_IECTRL_EXIST,
763 178, UNIPHIER_PIN_DRV_3BIT,
764 246, UNIPHIER_PIN_PULL_DOWN),
765 UNIPHIER_PINCTRL_PIN(247, "PORT14", UNIPHIER_PIN_IECTRL_EXIST,
766 179, UNIPHIER_PIN_DRV_3BIT,
767 247, UNIPHIER_PIN_PULL_DOWN),
768 UNIPHIER_PINCTRL_PIN(248, "PORT15", UNIPHIER_PIN_IECTRL_EXIST,
769 180, UNIPHIER_PIN_DRV_3BIT,
770 248, UNIPHIER_PIN_PULL_DOWN),
771 UNIPHIER_PINCTRL_PIN(249, "PORT16", UNIPHIER_PIN_IECTRL_EXIST,
772 181, UNIPHIER_PIN_DRV_3BIT,
773 249, UNIPHIER_PIN_PULL_DOWN),
774 UNIPHIER_PINCTRL_PIN(250, "PORT17", UNIPHIER_PIN_IECTRL_EXIST,
775 182, UNIPHIER_PIN_DRV_3BIT,
776 250, UNIPHIER_PIN_PULL_DOWN),
779 static const unsigned int emmc_pins[] = {32, 33, 34, 35, 36, 37, 38};
780 static const int emmc_muxvals[] = {0, 0, 0, 0, 0, 0, 0};
781 static const unsigned int emmc_dat8_pins[] = {39, 40, 41, 42};
782 static const int emmc_dat8_muxvals[] = {0, 0, 0, 0};
783 static const unsigned int ether_rgmii_pins[] = {52, 53, 54, 55, 56, 57, 58, 59,
784 60, 61, 62, 63, 64, 65, 66, 67};
785 static const int ether_rgmii_muxvals[] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
786 0, 0, 0};
787 static const unsigned int ether_rmii_pins[] = {52, 53, 54, 55, 56, 57, 58, 59,
788 61, 63, 64, 67};
789 static const int ether_rmii_muxvals[] = {0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1};
790 static const unsigned int ether1_rgmii_pins[] = {68, 69, 70, 71, 72, 73, 74,
791 75, 76, 77, 78, 79, 80, 81,
792 82, 83};
793 static const int ether1_rgmii_muxvals[] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
794 0, 0, 0, 0};
795 static const unsigned int ether1_rmii_pins[] = {68, 69, 70, 71, 72, 73, 74, 75,
796 77, 79, 80, 83};
797 static const int ether1_rmii_muxvals[] = {0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1};
798 static const unsigned int i2c0_pins[] = {104, 105};
799 static const int i2c0_muxvals[] = {0, 0};
800 static const unsigned int i2c1_pins[] = {106, 107};
801 static const int i2c1_muxvals[] = {0, 0};
802 static const unsigned int i2c2_pins[] = {108, 109};
803 static const int i2c2_muxvals[] = {0, 0};
804 static const unsigned int i2c3_pins[] = {110, 111};
805 static const int i2c3_muxvals[] = {0, 0};
806 static const unsigned int nand_pins[] = {16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
807 26, 27, 28, 29, 30};
808 static const int nand_muxvals[] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
809 static const unsigned int sd_pins[] = {43, 44, 45, 46, 47, 48, 49, 50, 51};
810 static const int sd_muxvals[] = {0, 0, 0, 0, 0, 0, 0, 0, 0};
811 static const unsigned int system_bus_pins[] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10,
812 11, 12, 13, 14};
813 static const int system_bus_muxvals[] = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
815 static const unsigned int system_bus_cs1_pins[] = {15};
816 static const int system_bus_cs1_muxvals[] = {0};
817 static const unsigned int uart0_pins[] = {92, 93};
818 static const int uart0_muxvals[] = {0, 0};
819 static const unsigned int uart1_pins[] = {94, 95};
820 static const int uart1_muxvals[] = {0, 0};
821 static const unsigned int uart2_pins[] = {96, 97};
822 static const int uart2_muxvals[] = {0, 0};
823 static const unsigned int uart3_pins[] = {98, 99};
824 static const int uart3_muxvals[] = {0, 0};
825 static const unsigned int usb0_pins[] = {84, 85};
826 static const int usb0_muxvals[] = {0, 0};
827 static const unsigned int usb1_pins[] = {86, 87};
828 static const int usb1_muxvals[] = {0, 0};
829 static const unsigned int usb2_pins[] = {88, 89};
830 static const int usb2_muxvals[] = {0, 0};
831 static const unsigned int usb3_pins[] = {90, 91};
832 static const int usb3_muxvals[] = {0, 0};
833 static const unsigned int gpio_range0_pins[] = {
834 235, 236, 237, 238, 239, 240, 241, 242, /* PORT0x */
835 243, 244, 245, 246, 247, 248, 249, 250, /* PORT1x */
836 0, 1, 2, 3, 4, 5, 6, 7, /* PORT2x */
837 8, 9, 10, 11, 12, 13, 14, 15, /* PORT3x */
838 16, 17, 18, 19, 20, 21, 22, 23, /* PORT4x */
839 24, 25, 26, 27, 28, 29, 30, 31, /* PORT5x */
840 43, 44, 45, 46, 47, 48, 49, 50, /* PORT6x */
841 51, 52, 53, 54, 55, 56, 57, 58, /* PORT7x */
842 59, 60, 61, 62, 63, 64, 65, 66, /* PORT8x */
843 67, 68, 69, 70, 71, 72, 73, 74, /* PORT9x */
844 75, 76, 77, 78, 79, 80, 81, 82, /* PORT10x */
846 static const unsigned int gpio_range1_pins[] = {
847 83, 84, 85, 86, 87, 88, 89, 90, /* PORT13x */
848 91, 92, 93, 94, 95, 96, 97, 98, /* PORT14x */
849 219, 220, 221, 222, 223, 224, 225, 226, /* XIRQ0-7 */
850 227, 228, 229, 230, 231, 232, 233, 234, /* XIRQ8-15 */
851 215, 216, 217, 218, 164, 165, 166, 167, /* XIRQ16-23 */
852 104, 105, 106, 107, 108, 109, 110, 111, /* PORT18x */
853 176, 177, 178, 179, 180, 181, 182, 183, /* PORT19x */
854 184, 185, /* PORT200-201 */
856 static const unsigned int gpio_range2_pins[] = {
857 99, 100, 101, 102, 103, 112, 113, 114, /* PORT21x */
858 115, 116, 117, 118, 119, 120, 121, 122, /* PORT22x */
859 123, 124, 125, 126, 127, 128, 129, 130, /* PORT23x */
860 131, 132, 133, 134, 135, 136, 137, 138, /* PORT24x */
861 139, 140, 141, 142, 143, 144, 145, 146, /* PORT25x */
862 147, 148, 149, 150, 151, 152, 153, 154, /* PORT26x */
863 155, 156, 157, 158, 159, 160, 161, 162, /* PORT27x */
864 163, 164, 165, 166, 167, 168, 169, 170, /* PORT28x */
865 171, 172, 173, 174, 175, 186, 187, 188, /* PORT29x */
866 189, 190, 191, 192, 193, 194, 195, 196, /* PORT30x */
867 197, 198, 199, 200, 201, 202, 203, 204, /* PORT31x */
868 205, 206, 207, 208, 209, 210, 211, 212, /* PORT32x */
869 213, 214, 215, 216, 217, 218, 219, 220, /* PORT33x */
870 221, 222, 223, 224, 225, 226, 227, 228, /* PORT34x */
871 229, 230, 231, 232, 233, 234, /* PORT350-355 */
874 static const struct uniphier_pinctrl_group uniphier_pxs3_groups[] = {
875 UNIPHIER_PINCTRL_GROUP(emmc),
876 UNIPHIER_PINCTRL_GROUP(emmc_dat8),
877 UNIPHIER_PINCTRL_GROUP(ether_rgmii),
878 UNIPHIER_PINCTRL_GROUP(ether_rmii),
879 UNIPHIER_PINCTRL_GROUP(ether1_rgmii),
880 UNIPHIER_PINCTRL_GROUP(ether1_rmii),
881 UNIPHIER_PINCTRL_GROUP(i2c0),
882 UNIPHIER_PINCTRL_GROUP(i2c1),
883 UNIPHIER_PINCTRL_GROUP(i2c2),
884 UNIPHIER_PINCTRL_GROUP(i2c3),
885 UNIPHIER_PINCTRL_GROUP(nand),
886 UNIPHIER_PINCTRL_GROUP(sd),
887 UNIPHIER_PINCTRL_GROUP(system_bus),
888 UNIPHIER_PINCTRL_GROUP(system_bus_cs1),
889 UNIPHIER_PINCTRL_GROUP(uart0),
890 UNIPHIER_PINCTRL_GROUP(uart1),
891 UNIPHIER_PINCTRL_GROUP(uart2),
892 UNIPHIER_PINCTRL_GROUP(uart3),
893 UNIPHIER_PINCTRL_GROUP(usb0),
894 UNIPHIER_PINCTRL_GROUP(usb1),
895 UNIPHIER_PINCTRL_GROUP(usb2),
896 UNIPHIER_PINCTRL_GROUP(usb3),
897 UNIPHIER_PINCTRL_GROUP_GPIO(gpio_range0),
898 UNIPHIER_PINCTRL_GROUP_GPIO(gpio_range1),
899 UNIPHIER_PINCTRL_GROUP_GPIO(gpio_range2),
902 static const char * const emmc_groups[] = {"emmc", "emmc_dat8"};
903 static const char * const ether_rgmii_groups[] = {"ether_rgmii"};
904 static const char * const ether_rmii_groups[] = {"ether_rmii"};
905 static const char * const ether1_rgmii_groups[] = {"ether1_rgmii"};
906 static const char * const ether1_rmii_groups[] = {"ether1_rmii"};
907 static const char * const i2c0_groups[] = {"i2c0"};
908 static const char * const i2c1_groups[] = {"i2c1"};
909 static const char * const i2c2_groups[] = {"i2c2"};
910 static const char * const i2c3_groups[] = {"i2c3"};
911 static const char * const nand_groups[] = {"nand"};
912 static const char * const sd_groups[] = {"sd"};
913 static const char * const system_bus_groups[] = {"system_bus",
914 "system_bus_cs1"};
915 static const char * const uart0_groups[] = {"uart0"};
916 static const char * const uart1_groups[] = {"uart1"};
917 static const char * const uart2_groups[] = {"uart2"};
918 static const char * const uart3_groups[] = {"uart3"};
919 static const char * const usb0_groups[] = {"usb0"};
920 static const char * const usb1_groups[] = {"usb1"};
921 static const char * const usb2_groups[] = {"usb2"};
922 static const char * const usb3_groups[] = {"usb3"};
924 static const struct uniphier_pinmux_function uniphier_pxs3_functions[] = {
925 UNIPHIER_PINMUX_FUNCTION(emmc),
926 UNIPHIER_PINMUX_FUNCTION(ether_rgmii),
927 UNIPHIER_PINMUX_FUNCTION(ether_rmii),
928 UNIPHIER_PINMUX_FUNCTION(ether1_rgmii),
929 UNIPHIER_PINMUX_FUNCTION(ether1_rmii),
930 UNIPHIER_PINMUX_FUNCTION(i2c0),
931 UNIPHIER_PINMUX_FUNCTION(i2c1),
932 UNIPHIER_PINMUX_FUNCTION(i2c2),
933 UNIPHIER_PINMUX_FUNCTION(i2c3),
934 UNIPHIER_PINMUX_FUNCTION(nand),
935 UNIPHIER_PINMUX_FUNCTION(sd),
936 UNIPHIER_PINMUX_FUNCTION(system_bus),
937 UNIPHIER_PINMUX_FUNCTION(uart0),
938 UNIPHIER_PINMUX_FUNCTION(uart1),
939 UNIPHIER_PINMUX_FUNCTION(uart2),
940 UNIPHIER_PINMUX_FUNCTION(uart3),
941 UNIPHIER_PINMUX_FUNCTION(usb0),
942 UNIPHIER_PINMUX_FUNCTION(usb1),
943 UNIPHIER_PINMUX_FUNCTION(usb2),
944 UNIPHIER_PINMUX_FUNCTION(usb3),
947 static int uniphier_pxs3_get_gpio_muxval(unsigned int pin,
948 unsigned int gpio_offset)
950 if (gpio_offset >= 120 && gpio_offset <= 143) { /* XIRQx */
951 if (pin >= 219 && pin <= 234)
952 return 0;
954 return 14;
957 return 15;
960 static struct uniphier_pinctrl_socdata uniphier_pxs3_pindata = {
961 .pins = uniphier_pxs3_pins,
962 .npins = ARRAY_SIZE(uniphier_pxs3_pins),
963 .groups = uniphier_pxs3_groups,
964 .groups_count = ARRAY_SIZE(uniphier_pxs3_groups),
965 .functions = uniphier_pxs3_functions,
966 .functions_count = ARRAY_SIZE(uniphier_pxs3_functions),
967 .get_gpio_muxval = uniphier_pxs3_get_gpio_muxval,
968 .caps = UNIPHIER_PINCTRL_CAPS_PERPIN_IECTRL,
971 static int uniphier_pxs3_pinctrl_probe(struct platform_device *pdev)
973 return uniphier_pinctrl_probe(pdev, &uniphier_pxs3_pindata);
976 static const struct of_device_id uniphier_pxs3_pinctrl_match[] = {
977 { .compatible = "socionext,uniphier-pxs3-pinctrl" },
978 { /* sentinel */ }
981 static struct platform_driver uniphier_pxs3_pinctrl_driver = {
982 .probe = uniphier_pxs3_pinctrl_probe,
983 .driver = {
984 .name = "uniphier-pxs3-pinctrl",
985 .of_match_table = uniphier_pxs3_pinctrl_match,
986 .pm = &uniphier_pinctrl_pm_ops,
989 builtin_platform_driver(uniphier_pxs3_pinctrl_driver);