1e87623cbSJens Kuske /*
2e87623cbSJens Kuske * Allwinner H3 SoCs pinctrl driver.
3e87623cbSJens Kuske *
4e87623cbSJens Kuske * Copyright (C) 2015 Jens Kuske <jenskuske@gmail.com>
5e87623cbSJens Kuske *
6e87623cbSJens Kuske * Based on pinctrl-sun8i-a23.c, which is:
7e87623cbSJens Kuske * Copyright (C) 2014 Chen-Yu Tsai <wens@csie.org>
8e87623cbSJens Kuske * Copyright (C) 2014 Maxime Ripard <maxime.ripard@free-electrons.com>
9e87623cbSJens Kuske *
10e87623cbSJens Kuske * This file is licensed under the terms of the GNU General Public
11e87623cbSJens Kuske * License version 2. This program is licensed "as is" without any
12e87623cbSJens Kuske * warranty of any kind, whether express or implied.
13e87623cbSJens Kuske */
14e87623cbSJens Kuske
15e87623cbSJens Kuske #include <linux/module.h>
16e87623cbSJens Kuske #include <linux/platform_device.h>
17e87623cbSJens Kuske #include <linux/of.h>
18e87623cbSJens Kuske #include <linux/pinctrl/pinctrl.h>
19e87623cbSJens Kuske
20e87623cbSJens Kuske #include "pinctrl-sunxi.h"
21e87623cbSJens Kuske
22e87623cbSJens Kuske static const struct sunxi_desc_pin sun8i_h3_pins[] = {
23e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 0),
24e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
25e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
26e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart2"), /* TX */
27e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag"), /* MS */
28e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 0)), /* PA_EINT0 */
29e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 1),
30e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
31e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
32e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart2"), /* RX */
33e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag"), /* CK */
34e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 1)), /* PA_EINT1 */
35e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 2),
36e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
37e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
38e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart2"), /* RTS */
39e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag"), /* DO */
40e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 2)), /* PA_EINT2 */
41e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 3),
42e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
43e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
44e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart2"), /* CTS */
45e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag"), /* DI */
46e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 3)), /* PA_EINT3 */
47e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 4),
48e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
49e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
50e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart0"), /* TX */
51e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 4)), /* PA_EINT4 */
52e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 5),
53e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
54e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
55e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart0"), /* RX */
56e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "pwm0"),
57e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 5)), /* PA_EINT5 */
58e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 6),
59e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
60e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
61e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "sim"), /* PWREN */
62e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 6)), /* PA_EINT6 */
63e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 7),
64e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
65e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
66e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "sim"), /* CLK */
67e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 7)), /* PA_EINT7 */
68e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 8),
69e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
70e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
71e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "sim"), /* DATA */
72e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 8)), /* PA_EINT8 */
73e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 9),
74e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
75e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
76e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "sim"), /* RST */
77e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 9)), /* PA_EINT9 */
78e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 10),
79e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
80e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
81e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "sim"), /* DET */
82e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 10)), /* PA_EINT10 */
83e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 11),
84e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
85e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
86e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2c0"), /* SCK */
87e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "di"), /* TX */
88e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 11)), /* PA_EINT11 */
89e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 12),
90e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
91e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
92e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2c0"), /* SDA */
93e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "di"), /* RX */
94e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 12)), /* PA_EINT12 */
95e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 13),
96e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
97e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
98e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "spi1"), /* CS */
99e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "uart3"), /* TX */
100e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 13)), /* PA_EINT13 */
101e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 14),
102e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
103e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
104e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "spi1"), /* CLK */
105e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "uart3"), /* RX */
106e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 14)), /* PA_EINT14 */
107e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 15),
108e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
109e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
110e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "spi1"), /* MOSI */
111e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "uart3"), /* RTS */
112e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 15)), /* PA_EINT15 */
113e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 16),
114e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
115e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
116e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "spi1"), /* MISO */
117e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "uart3"), /* CTS */
118e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 16)), /* PA_EINT16 */
119e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 17),
120e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
121e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
122e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "spdif"), /* OUT */
123e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 17)), /* PA_EINT17 */
124e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 18),
125e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
126e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
127e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s0"), /* SYNC */
128e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "i2c1"), /* SCK */
129e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 18)), /* PA_EINT18 */
130e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 19),
131e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
132e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
133e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s0"), /* CLK */
134e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "i2c1"), /* SDA */
135e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 19)), /* PA_EINT19 */
136e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 20),
137e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
138e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
139e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s0"), /* DOUT */
140e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "sim"), /* VPPEN */
141e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 20)), /* PA_EINT20 */
142e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(A, 21),
143e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
144e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
145e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s0"), /* DIN */
146e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "sim"), /* VPPPP */
147e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 21)), /* PA_EINT21 */
148e87623cbSJens Kuske /* Hole */
149e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 0),
150e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
151e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
152e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* WE */
153e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "spi0")), /* MOSI */
154e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 1),
155e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
156e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
157e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* ALE */
158e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "spi0")), /* MISO */
159e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 2),
160e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
161e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
162e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* CLE */
163e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "spi0")), /* CLK */
164e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 3),
165e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
166e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
167e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* CE1 */
168e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "spi0")), /* CS */
169e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 4),
170e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
171e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
172e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0")), /* CE0 */
173e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 5),
174e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
175e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
176e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* RE */
177e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* CLK */
178e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 6),
179e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
180e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
181e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* RB0 */
182e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* CMD */
183e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 7),
184e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
185e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
186e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0")), /* RB1 */
187e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 8),
188e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
189e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
190e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* DQ0 */
191e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D0 */
192e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 9),
193e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
194e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
195e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* DQ1 */
196e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D1 */
197e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 10),
198e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
199e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
200e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* DQ2 */
201e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D2 */
202e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 11),
203e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
204e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
205e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* DQ3 */
206e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D3 */
207e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 12),
208e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
209e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
210e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* DQ4 */
211e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D4 */
212e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 13),
213e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
214e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
215e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "nand0"), /* DQ5 */
216e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D5 */
217e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 14),
218e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
219e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
220bc0f566aSIcenowy Zheng SUNXI_FUNCTION(0x2, "nand0"), /* DQ6 */
221e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D6 */
222e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 15),
223e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
224e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
225bc0f566aSIcenowy Zheng SUNXI_FUNCTION(0x2, "nand0"), /* DQ7 */
226e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* D7 */
227e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 16),
228e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
229e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
230bc0f566aSIcenowy Zheng SUNXI_FUNCTION(0x2, "nand0"), /* DQS */
231e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "mmc2")), /* RST */
232e87623cbSJens Kuske /* Hole */
233e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 0),
234e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
235e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
236e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXD3 */
237e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 1),
238e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
239e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
240e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXD2 */
241e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 2),
242e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
243e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
244e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXD1 */
245e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 3),
246e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
247e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
248e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXD0 */
249e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 4),
250e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
251e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
252e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXCK */
253e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 5),
254e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
255e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
256e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXCTL/RXDV */
257e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 6),
258e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
259e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
260e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* RXERR */
261e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 7),
262e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
263e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
264e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXD3 */
265e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 8),
266e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
267e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
268e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXD2 */
269e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 9),
270e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
271e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
272e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXD1 */
273e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 10),
274e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
275e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
276e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXD0 */
277e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 11),
278e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
279e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
280e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* CRS */
281e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 12),
282e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
283e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
284e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXCK */
285e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 13),
286e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
287e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
288e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXCTL/TXEN */
289e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 14),
290e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
291e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
292e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* TXERR */
293e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 15),
294e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
295e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
296e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* CLKIN/COL */
297e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 16),
298e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
299e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
300e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* MDC */
301e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 17),
302e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
303e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
304e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "emac")), /* MDIO */
305e87623cbSJens Kuske /* Hole */
306e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 0),
307e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
308e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
309e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* PCLK */
310e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* CLK */
311e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 1),
312e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
313e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
314e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* MCLK */
315e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* ERR */
316e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 2),
317e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
318e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
319e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* HSYNC */
320e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* SYNC */
321e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 3),
322e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
323e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
324e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* VSYNC */
325e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* DVLD */
326e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 4),
327e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
328e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
329e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D0 */
330e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D0 */
331e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 5),
332e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
333e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
334e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D1 */
335e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D1 */
336e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 6),
337e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
338e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
339e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D2 */
340e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D2 */
341e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 7),
342e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
343e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
344e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D3 */
345e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D3 */
346e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 8),
347e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
348e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
349e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D4 */
350e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D4 */
351e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 9),
352e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
353e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
354e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D5 */
355e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D5 */
356e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 10),
357e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
358e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
359e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D6 */
360e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D6 */
361e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 11),
362e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
363e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
364e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* D7 */
365e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "ts")), /* D7 */
366e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 12),
367e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
368e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
369e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* SCK */
370e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "i2c2")), /* SCK */
371e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 13),
372e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
373e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
374e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "csi"), /* SDA */
375e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "i2c2")), /* SDA */
376e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 14),
377e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
378e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out")),
379e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(E, 15),
380e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
381e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out")),
382e87623cbSJens Kuske /* Hole */
383e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 0),
384e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
385e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
386e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc0"), /* D1 */
387e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag")), /* MS */
388e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 1),
389e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
390e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
391e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc0"), /* D0 */
392e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag")), /* DI */
393e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 2),
394e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
395e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
396e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc0"), /* CLK */
397e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "uart0")), /* TX */
398e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 3),
399e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
400e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
401e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc0"), /* CMD */
402e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag")), /* DO */
403e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 4),
404e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
405e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
406e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc0"), /* D3 */
407e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "uart0")), /* RX */
408e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 5),
409e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
410e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
411e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc0"), /* D2 */
412e87623cbSJens Kuske SUNXI_FUNCTION(0x3, "jtag")), /* CK */
413e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(F, 6),
414e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
415e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out")),
416e87623cbSJens Kuske /* Hole */
417e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 0),
418e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
419e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
420e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc1"), /* CLK */
421e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 0)), /* PG_EINT0 */
422e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 1),
423e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
424e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
425e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc1"), /* CMD */
426e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 1)), /* PG_EINT1 */
427e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 2),
428e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
429e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
430e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc1"), /* D0 */
431e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 2)), /* PG_EINT2 */
432e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 3),
433e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
434e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
435e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc1"), /* D1 */
436e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 3)), /* PG_EINT3 */
437e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 4),
438e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
439e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
440e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc1"), /* D2 */
441e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 4)), /* PG_EINT4 */
442e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 5),
443e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
444e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
445e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "mmc1"), /* D3 */
446e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 5)), /* PG_EINT5 */
447e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 6),
448e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
449e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
450e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart1"), /* TX */
451e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 6)), /* PG_EINT6 */
452e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 7),
453e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
454e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
455e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart1"), /* RX */
456e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 7)), /* PG_EINT7 */
457e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 8),
458e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
459e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
460e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart1"), /* RTS */
461e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 8)), /* PG_EINT8 */
462e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 9),
463e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
464e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
465e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "uart1"), /* CTS */
466e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 9)), /* PG_EINT9 */
467e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 10),
468e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
469e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
470e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s1"), /* SYNC */
471e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 10)), /* PG_EINT10 */
472e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 11),
473e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
474e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
475e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s1"), /* CLK */
476e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 11)), /* PG_EINT11 */
477e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 12),
478e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
479e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
480e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s1"), /* DOUT */
481e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 12)), /* PG_EINT12 */
482e87623cbSJens Kuske SUNXI_PIN(SUNXI_PINCTRL_PIN(G, 13),
483e87623cbSJens Kuske SUNXI_FUNCTION(0x0, "gpio_in"),
484e87623cbSJens Kuske SUNXI_FUNCTION(0x1, "gpio_out"),
485e87623cbSJens Kuske SUNXI_FUNCTION(0x2, "i2s1"), /* DIN */
486e87623cbSJens Kuske SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 13)), /* PG_EINT13 */
487e87623cbSJens Kuske };
488e87623cbSJens Kuske
489e87623cbSJens Kuske static const struct sunxi_pinctrl_desc sun8i_h3_pinctrl_data = {
490e87623cbSJens Kuske .pins = sun8i_h3_pins,
491e87623cbSJens Kuske .npins = ARRAY_SIZE(sun8i_h3_pins),
492e87623cbSJens Kuske .irq_banks = 2,
493*cd70387fSMaxime Ripard .irq_read_needs_mux = true,
494*cd70387fSMaxime Ripard .disable_strict_mode = true,
495e87623cbSJens Kuske };
496e87623cbSJens Kuske
sun8i_h3_pinctrl_probe(struct platform_device * pdev)497e87623cbSJens Kuske static int sun8i_h3_pinctrl_probe(struct platform_device *pdev)
498e87623cbSJens Kuske {
499e87623cbSJens Kuske return sunxi_pinctrl_init(pdev,
500e87623cbSJens Kuske &sun8i_h3_pinctrl_data);
501e87623cbSJens Kuske }
502e87623cbSJens Kuske
503e87623cbSJens Kuske static const struct of_device_id sun8i_h3_pinctrl_match[] = {
504e87623cbSJens Kuske { .compatible = "allwinner,sun8i-h3-pinctrl", },
505e87623cbSJens Kuske {}
506e87623cbSJens Kuske };
507e87623cbSJens Kuske
508e87623cbSJens Kuske static struct platform_driver sun8i_h3_pinctrl_driver = {
509e87623cbSJens Kuske .probe = sun8i_h3_pinctrl_probe,
510e87623cbSJens Kuske .driver = {
511e87623cbSJens Kuske .name = "sun8i-h3-pinctrl",
512e87623cbSJens Kuske .of_match_table = sun8i_h3_pinctrl_match,
513e87623cbSJens Kuske },
514e87623cbSJens Kuske };
515e87623cbSJens Kuske builtin_platform_driver(sun8i_h3_pinctrl_driver);
516