1 == MediaTek MT7622 pinctrl controller ==
3 Required properties for the root node:
4 - compatible: Should be one of the following
5 "mediatek,mt7622-pinctrl" for MT7622 SoC
6 "mediatek,mt7629-pinctrl" for MT7629 SoC
7 - reg: offset and length of the pinctrl space
9 - gpio-controller: Marks the device node as a GPIO controller.
10 - #gpio-cells: Should be two. The first cell is the pin number and the
11 second is the GPIO flags.
14 - interrupt-controller : Marks the device node as an interrupt controller
16 If the property interrupt-controller is defined, following property is required
17 - reg-names: A string describing the "reg" entries. Must contain "eint".
18 - interrupts : The interrupt output from the controller.
19 - #interrupt-cells: Should be two.
21 Please refer to pinctrl-bindings.txt in this directory for details of the
22 common pinctrl bindings used by client devices, including the meaning of the
23 phrase "pin configuration node".
25 MT7622 pin configuration nodes act as a container for an arbitrary number of
26 subnodes. Each of these subnodes represents some desired configuration for a
27 pin, a group, or a list of pins or groups. This configuration can include the
28 mux function to select on those pin(s)/group(s), and various pin configuration
29 parameters, such as pull-up, slew rate, etc.
31 We support 2 types of configuration nodes. Those nodes can be either pinmux
32 nodes or pinconf nodes. Each configuration node can consist of multiple nodes
33 describing the pinmux and pinconf options.
35 The name of each subnode doesn't matter as long as it is unique; all subnodes
36 should be enumerated and processed purely based on their content.
38 == pinmux nodes content ==
40 The following generic properties as defined in pinctrl-bindings.txt are valid
41 to specify in a pinmux subnode:
43 Required properties are:
44 - groups: An array of strings. Each string contains the name of a group.
45 Valid values for these names are listed below.
46 - function: A string containing the name of the function to mux to the
47 group. Valid values for function names are listed below.
49 == pinconf nodes content ==
51 The following generic properties as defined in pinctrl-bindings.txt are valid
52 to specify in a pinconf subnode:
54 Required properties are:
55 - pins: An array of strings. Each string contains the name of a pin.
56 Valid values for these names are listed below.
57 - groups: An array of strings. Each string contains the name of a group.
58 Valid values for these names are listed below.
60 Optional properies are:
61 bias-disable, bias-pull, bias-pull-down, input-enable,
62 input-schmitt-enable, input-schmitt-disable, output-enable
63 output-low, output-high, drive-strength, slew-rate
65 Valid arguments for 'slew-rate' are '0' for no slew rate controlled and '1' for
66 slower slew rate respectively.
67 Valid arguments for 'drive-strength', 4, 8, 12, or 16 in mA.
69 The following specific properties as defined are valid to specify in a pinconf
72 Optional properties are:
73 - mediatek,tdsel: An integer describing the steps for output level shifter duty
74 cycle when asserted (high pulse width adjustment). Valid arguments are from 0
76 - mediatek,rdsel: An integer describing the steps for input level shifter duty
77 cycle when asserted (high pulse width adjustment). Valid arguments are from 0
80 == Valid values for pins, function and groups on MT7622 ==
82 Valid values for pins are:
83 pins can be referenced via the pin names as the below table shown and the
84 related physical number is also put ahead of those names which helps cross
85 references to pins between groups to know whether pins assignment conflict
86 happens among devices try to acquire those available pins.
88 Pin #: Valid values for pins
89 -----------------------------
176 PIN 86: "EPHY_LED0_N"
194 Valid values for function are:
195 "emmc", "eth", "i2c", "i2s", "ir", "led", "flash", "pcie",
196 "pmic", "pwm", "sd", "spi", "tdm", "uart", "watchdog"
198 Valid values for groups are:
199 additional data is put followingly with valid value allowing us to know which
200 applicable function and which relevant pins (in pin#) are able applied for that
203 Valid value function pins (in pin#)
204 -------------------------------------------------------------------------
205 "emmc" "emmc" 40, 41, 42, 43, 44, 45,
208 "esw" "eth" 51, 52, 53, 54, 55, 56,
209 57, 58, 59, 60, 61, 62,
210 63, 64, 65, 66, 67, 68,
212 "esw_p0_p1" "eth" 51, 52, 53, 54, 55, 56,
214 "esw_p2_p3_p4" "eth" 59, 60, 61, 62, 63, 64,
215 65, 66, 67, 68, 69, 70
216 "rgmii_via_esw" "eth" 59, 60, 61, 62, 63, 64,
217 65, 66, 67, 68, 69, 70
218 "rgmii_via_gmac1" "eth" 59, 60, 61, 62, 63, 64,
219 65, 66, 67, 68, 69, 70
220 "rgmii_via_gmac2" "eth" 25, 26, 27, 28, 29, 30,
221 31, 32, 33, 34, 35, 36
222 "mdc_mdio" "eth" 23, 24
224 "i2c1_0" "i2c" 55, 56
225 "i2c1_1" "i2c" 73, 74
226 "i2c1_2" "i2c" 87, 88
227 "i2c2_0" "i2c" 57, 58
228 "i2c2_1" "i2c" 75, 76
229 "i2c2_2" "i2c" 89, 90
230 "i2s_in_mclk_bclk_ws" "i2s" 3, 4, 5
231 "i2s1_in_data" "i2s" 1
232 "i2s2_in_data" "i2s" 16
233 "i2s3_in_data" "i2s" 17
234 "i2s4_in_data" "i2s" 18
235 "i2s_out_mclk_bclk_ws" "i2s" 3, 4, 5
236 "i2s1_out_data" "i2s" 2
237 "i2s2_out_data" "i2s" 19
238 "i2s3_out_data" "i2s" 20
239 "i2s4_out_data" "i2s" 21
246 "ephy_leds" "led" 86, 91, 92, 93, 94
253 "par_nand" "flash" 37, 38, 39, 40, 41, 42,
254 43, 44, 45, 46, 47, 48,
256 "snfi" "flash" 8, 9, 10, 11, 12, 13
257 "spi_nor" "flash" 8, 9, 10, 11, 12, 13
258 "pcie0_0_waken" "pcie" 14
259 "pcie0_1_waken" "pcie" 79
260 "pcie1_0_waken" "pcie" 14
261 "pcie0_0_clkreq" "pcie" 15
262 "pcie0_1_clkreq" "pcie" 80
263 "pcie1_0_clkreq" "pcie" 15
264 "pcie0_pad_perst" "pcie" 83
265 "pcie1_pad_perst" "pcie" 84
266 "pmic_bus" "pmic" 71, 72
286 "pwm_ch6_3" "pwm" 100
289 "pwm_ch7_2" "pwm" 101
290 "sd_0" "sd" 16, 17, 18, 19, 20, 21
291 "sd_1" "sd" 25, 26, 27, 28, 29, 30
292 "spic0_0" "spi" 63, 64, 65, 66
293 "spic0_1" "spi" 79, 80, 81, 82
294 "spic1_0" "spi" 67, 68, 69, 70
295 "spic1_1" "spi" 73, 74, 75, 76
296 "spic2_0_wp_hold" "spi" 8, 9
297 "spic2_0" "spi" 10, 11, 12, 13
298 "tdm_0_out_mclk_bclk_ws" "tdm" 8, 9, 10
299 "tdm_0_in_mclk_bclk_ws" "tdm" 11, 12, 13
300 "tdm_0_out_data" "tdm" 20
301 "tdm_0_in_data" "tdm" 21
302 "tdm_1_out_mclk_bclk_ws" "tdm" 57, 58, 59
303 "tdm_1_in_mclk_bclk_ws" "tdm" 60, 61, 62
304 "tdm_1_out_data" "tdm" 55
305 "tdm_1_in_data" "tdm" 56
306 "uart0_0_tx_rx" "uart" 6, 7
307 "uart1_0_tx_rx" "uart" 55, 56
308 "uart1_0_rts_cts" "uart" 57, 58
309 "uart1_1_tx_rx" "uart" 73, 74
310 "uart1_1_rts_cts" "uart" 75, 76
311 "uart2_0_tx_rx" "uart" 3, 4
312 "uart2_0_rts_cts" "uart" 1, 2
313 "uart2_1_tx_rx" "uart" 51, 52
314 "uart2_1_rts_cts" "uart" 53, 54
315 "uart2_2_tx_rx" "uart" 59, 60
316 "uart2_2_rts_cts" "uart" 61, 62
317 "uart2_3_tx_rx" "uart" 95, 96
318 "uart3_0_tx_rx" "uart" 57, 58
319 "uart3_1_tx_rx" "uart" 81, 82
320 "uart3_1_rts_cts" "uart" 79, 80
321 "uart4_0_tx_rx" "uart" 61, 62
322 "uart4_1_tx_rx" "uart" 91, 92
323 "uart4_1_rts_cts" "uart" 93, 94
324 "uart4_2_tx_rx" "uart" 97, 98
325 "uart4_2_rts_cts" "uart" 95, 96
326 "watchdog" "watchdog" 78
329 == Valid values for pins, function and groups on MT7629 ==
331 Pin #: Valid values for pins
332 -----------------------------
344 PIN 11: "SYS_WATCHDOG"
345 PIN 12: "EPHY_LED0_N_JTDO"
346 PIN 13: "EPHY_LED1_N_JTDI"
347 PIN 14: "EPHY_LED2_N_JTMS"
348 PIN 15: "EPHY_LED3_N_JTCLK"
349 PIN 16: "EPHY_LED4_N_JTRST_N"
384 PIN 51: "PCIE_PERESET_N"
404 PIN 71: "TOP_2G_DATA"
413 Valid values for function are:
414 "eth", "i2c", "led", "flash", "pcie", "pwm", "spi", "uart",
417 Valid values for groups are:
418 Valid value function pins (in pin#)
419 ----------------------------------------------------------------
420 "mdc_mdio" "eth" 23, 24
423 "ephy_leds" "led" 12, 13, 14, 15, 16,
432 "snfi" "flash" 62, 63, 64, 65, 66, 67
433 "spi_nor" "flash" 62, 63, 64, 65, 66, 67
434 "pcie_pereset" "pcie" 51
435 "pcie_wake" "pcie" 55
436 "pcie_clkreq" "pcie" 56
439 "spi_0" "spi" 21, 22, 23, 24
440 "spi_1" "spi" 62, 63, 64, 65
443 "uart0_txd_rxd" "uart" 68, 69
444 "uart1_0_txd_rxd" "uart" 25, 26
445 "uart1_0_cts_rts" "uart" 27, 28
446 "uart1_1_txd_rxd" "uart" 53, 54
447 "uart1_1_cts_rts" "uart" 55, 56
448 "uart2_0_txd_rxd" "uart" 29, 30
449 "uart2_0_cts_rts" "uart" 31, 32
450 "uart2_1_txd_rxd" "uart" 57, 58
451 "uart2_1_cts_rts" "uart" 59, 60
452 "watchdog" "watchdog" 11
453 "wf0_2g" "wifi" 70, 71, 72, 73, 74,
455 "wf0_5g" "wifi" 0, 1, 2, 3, 4, 5, 6,
460 pio: pinctrl@10211000 {
461 compatible = "mediatek,mt7622-pinctrl";
462 reg = <0 0x10211000 0 0x1000>;
466 pinctrl_eth_default: eth-default {
470 drive-strength = <12>;
476 drive-strength = <12>;
482 drive-strength = <8>;