16be33864SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 26be33864SEmmanuel Vadot%YAML 1.2 36be33864SEmmanuel Vadot--- 46be33864SEmmanuel Vadot$id: http://devicetree.org/schemas/pinctrl/renesas,pfc.yaml# 56be33864SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 66be33864SEmmanuel Vadot 76be33864SEmmanuel Vadottitle: Renesas Pin Function Controller (GPIO and Pin Mux/Config) 86be33864SEmmanuel Vadot 96be33864SEmmanuel Vadotmaintainers: 106be33864SEmmanuel Vadot - Geert Uytterhoeven <geert+renesas@glider.be> 116be33864SEmmanuel Vadot 126be33864SEmmanuel Vadotdescription: 136be33864SEmmanuel Vadot The Pin Function Controller (PFC) is a Pin Mux/Config controller. 146be33864SEmmanuel Vadot On SH/R-Mobile SoCs it also acts as a GPIO controller. 156be33864SEmmanuel Vadot 166be33864SEmmanuel Vadotproperties: 176be33864SEmmanuel Vadot compatible: 186be33864SEmmanuel Vadot enum: 196be33864SEmmanuel Vadot - renesas,pfc-emev2 # EMMA Mobile EV2 206be33864SEmmanuel Vadot - renesas,pfc-r8a73a4 # R-Mobile APE6 216be33864SEmmanuel Vadot - renesas,pfc-r8a7740 # R-Mobile A1 226be33864SEmmanuel Vadot - renesas,pfc-r8a7742 # RZ/G1H 236be33864SEmmanuel Vadot - renesas,pfc-r8a7743 # RZ/G1M 246be33864SEmmanuel Vadot - renesas,pfc-r8a7744 # RZ/G1N 256be33864SEmmanuel Vadot - renesas,pfc-r8a7745 # RZ/G1E 266be33864SEmmanuel Vadot - renesas,pfc-r8a77470 # RZ/G1C 276be33864SEmmanuel Vadot - renesas,pfc-r8a774a1 # RZ/G2M 286be33864SEmmanuel Vadot - renesas,pfc-r8a774b1 # RZ/G2N 296be33864SEmmanuel Vadot - renesas,pfc-r8a774c0 # RZ/G2E 306be33864SEmmanuel Vadot - renesas,pfc-r8a774e1 # RZ/G2H 316be33864SEmmanuel Vadot - renesas,pfc-r8a7778 # R-Car M1 326be33864SEmmanuel Vadot - renesas,pfc-r8a7779 # R-Car H1 336be33864SEmmanuel Vadot - renesas,pfc-r8a7790 # R-Car H2 346be33864SEmmanuel Vadot - renesas,pfc-r8a7791 # R-Car M2-W 356be33864SEmmanuel Vadot - renesas,pfc-r8a7792 # R-Car V2H 366be33864SEmmanuel Vadot - renesas,pfc-r8a7793 # R-Car M2-N 376be33864SEmmanuel Vadot - renesas,pfc-r8a7794 # R-Car E2 386be33864SEmmanuel Vadot - renesas,pfc-r8a7795 # R-Car H3 396be33864SEmmanuel Vadot - renesas,pfc-r8a7796 # R-Car M3-W 406be33864SEmmanuel Vadot - renesas,pfc-r8a77961 # R-Car M3-W+ 416be33864SEmmanuel Vadot - renesas,pfc-r8a77965 # R-Car M3-N 426be33864SEmmanuel Vadot - renesas,pfc-r8a77970 # R-Car V3M 436be33864SEmmanuel Vadot - renesas,pfc-r8a77980 # R-Car V3H 446be33864SEmmanuel Vadot - renesas,pfc-r8a77990 # R-Car E3 456be33864SEmmanuel Vadot - renesas,pfc-r8a77995 # R-Car D3 465def4c47SEmmanuel Vadot - renesas,pfc-r8a779a0 # R-Car V3U 47c9ccf3a3SEmmanuel Vadot - renesas,pfc-r8a779f0 # R-Car S4-8 48b97ee269SEmmanuel Vadot - renesas,pfc-r8a779g0 # R-Car V4H 496be33864SEmmanuel Vadot - renesas,pfc-sh73a0 # SH-Mobile AG5 506be33864SEmmanuel Vadot 516be33864SEmmanuel Vadot reg: 526be33864SEmmanuel Vadot minItems: 1 535def4c47SEmmanuel Vadot maxItems: 10 546be33864SEmmanuel Vadot 556be33864SEmmanuel Vadot gpio-controller: true 566be33864SEmmanuel Vadot 576be33864SEmmanuel Vadot '#gpio-cells': 586be33864SEmmanuel Vadot const: 2 596be33864SEmmanuel Vadot 606be33864SEmmanuel Vadot gpio-ranges: 616be33864SEmmanuel Vadot minItems: 1 626be33864SEmmanuel Vadot maxItems: 16 636be33864SEmmanuel Vadot 646be33864SEmmanuel Vadot interrupts-extended: 656be33864SEmmanuel Vadot minItems: 32 666be33864SEmmanuel Vadot maxItems: 64 676be33864SEmmanuel Vadot description: 686be33864SEmmanuel Vadot Specify the interrupts associated with external IRQ pins on SoCs where 696be33864SEmmanuel Vadot the PFC acts as a GPIO controller. It must contain one interrupt per 706be33864SEmmanuel Vadot external IRQ, sorted by external IRQ number. 716be33864SEmmanuel Vadot 726be33864SEmmanuel Vadot power-domains: 736be33864SEmmanuel Vadot maxItems: 1 746be33864SEmmanuel Vadot 75e67e8565SEmmanuel VadotallOf: 76*fac71e4eSEmmanuel Vadot - $ref: pinctrl.yaml# 77e67e8565SEmmanuel Vadot 786be33864SEmmanuel Vadotrequired: 796be33864SEmmanuel Vadot - compatible 806be33864SEmmanuel Vadot - reg 816be33864SEmmanuel Vadot 826be33864SEmmanuel Vadotif: 836be33864SEmmanuel Vadot properties: 846be33864SEmmanuel Vadot compatible: 856be33864SEmmanuel Vadot enum: 866be33864SEmmanuel Vadot - renesas,pfc-r8a73a4 876be33864SEmmanuel Vadot - renesas,pfc-r8a7740 886be33864SEmmanuel Vadot - renesas,pfc-sh73a0 896be33864SEmmanuel Vadotthen: 906be33864SEmmanuel Vadot required: 916be33864SEmmanuel Vadot - interrupts-extended 926be33864SEmmanuel Vadot - gpio-controller 936be33864SEmmanuel Vadot - '#gpio-cells' 946be33864SEmmanuel Vadot - gpio-ranges 956be33864SEmmanuel Vadot - power-domains 966be33864SEmmanuel Vadot 976be33864SEmmanuel VadotadditionalProperties: 986be33864SEmmanuel Vadot anyOf: 996be33864SEmmanuel Vadot - type: object 1006be33864SEmmanuel Vadot allOf: 1016be33864SEmmanuel Vadot - $ref: pincfg-node.yaml# 1026be33864SEmmanuel Vadot - $ref: pinmux-node.yaml# 1036be33864SEmmanuel Vadot 1046be33864SEmmanuel Vadot description: 1056be33864SEmmanuel Vadot Pin controller client devices use pin configuration subnodes (children 1066be33864SEmmanuel Vadot and grandchildren) for desired pin configuration. 1076be33864SEmmanuel Vadot Client device subnodes use below standard properties. 1086be33864SEmmanuel Vadot 1096be33864SEmmanuel Vadot properties: 1106be33864SEmmanuel Vadot function: true 1116be33864SEmmanuel Vadot groups: true 1126be33864SEmmanuel Vadot pins: true 1136be33864SEmmanuel Vadot bias-disable: true 1146be33864SEmmanuel Vadot bias-pull-down: true 1156be33864SEmmanuel Vadot bias-pull-up: true 1166be33864SEmmanuel Vadot drive-strength: 1176be33864SEmmanuel Vadot enum: [ 3, 6, 9, 12, 15, 18, 21, 24 ] # Superset of supported values 1186be33864SEmmanuel Vadot power-source: 1196be33864SEmmanuel Vadot enum: [ 1800, 3300 ] 1206be33864SEmmanuel Vadot gpio-hog: true 1216be33864SEmmanuel Vadot gpios: true 1226be33864SEmmanuel Vadot input: true 1236be33864SEmmanuel Vadot output-high: true 1246be33864SEmmanuel Vadot output-low: true 1256be33864SEmmanuel Vadot 1266be33864SEmmanuel Vadot additionalProperties: false 1276be33864SEmmanuel Vadot 1286be33864SEmmanuel Vadot - type: object 1296be33864SEmmanuel Vadot additionalProperties: 1306be33864SEmmanuel Vadot $ref: "#/additionalProperties/anyOf/0" 1316be33864SEmmanuel Vadot 1326be33864SEmmanuel Vadotexamples: 1336be33864SEmmanuel Vadot - | 1346be33864SEmmanuel Vadot pfc: pinctrl@e6050000 { 1356be33864SEmmanuel Vadot compatible = "renesas,pfc-r8a7740"; 1366be33864SEmmanuel Vadot reg = <0xe6050000 0x8000>, 1376be33864SEmmanuel Vadot <0xe605800c 0x20>; 1386be33864SEmmanuel Vadot gpio-controller; 1396be33864SEmmanuel Vadot #gpio-cells = <2>; 1406be33864SEmmanuel Vadot gpio-ranges = <&pfc 0 0 212>; 1416be33864SEmmanuel Vadot interrupts-extended = 1426be33864SEmmanuel Vadot <&irqpin0 0 0>, <&irqpin0 1 0>, <&irqpin0 2 0>, <&irqpin0 3 0>, 1436be33864SEmmanuel Vadot <&irqpin0 4 0>, <&irqpin0 5 0>, <&irqpin0 6 0>, <&irqpin0 7 0>, 1446be33864SEmmanuel Vadot <&irqpin1 0 0>, <&irqpin1 1 0>, <&irqpin1 2 0>, <&irqpin1 3 0>, 1456be33864SEmmanuel Vadot <&irqpin1 4 0>, <&irqpin1 5 0>, <&irqpin1 6 0>, <&irqpin1 7 0>, 1466be33864SEmmanuel Vadot <&irqpin2 0 0>, <&irqpin2 1 0>, <&irqpin2 2 0>, <&irqpin2 3 0>, 1476be33864SEmmanuel Vadot <&irqpin2 4 0>, <&irqpin2 5 0>, <&irqpin2 6 0>, <&irqpin2 7 0>, 1486be33864SEmmanuel Vadot <&irqpin3 0 0>, <&irqpin3 1 0>, <&irqpin3 2 0>, <&irqpin3 3 0>, 1496be33864SEmmanuel Vadot <&irqpin3 4 0>, <&irqpin3 5 0>, <&irqpin3 6 0>, <&irqpin3 7 0>; 1506be33864SEmmanuel Vadot power-domains = <&pd_c5>; 1516be33864SEmmanuel Vadot 1526be33864SEmmanuel Vadot lcd0-mux-hog { 1536be33864SEmmanuel Vadot /* DBGMD/LCDC0/FSIA MUX */ 1546be33864SEmmanuel Vadot gpio-hog; 1556be33864SEmmanuel Vadot gpios = <176 0>; 1566be33864SEmmanuel Vadot output-high; 1576be33864SEmmanuel Vadot }; 1586be33864SEmmanuel Vadot }; 1596be33864SEmmanuel Vadot 1606be33864SEmmanuel Vadot - | 1616be33864SEmmanuel Vadot pinctrl@e6060000 { 1626be33864SEmmanuel Vadot compatible = "renesas,pfc-r8a7795"; 1636be33864SEmmanuel Vadot reg = <0xe6060000 0x50c>; 1646be33864SEmmanuel Vadot 1656be33864SEmmanuel Vadot avb_pins: avb { 1666be33864SEmmanuel Vadot mux { 1676be33864SEmmanuel Vadot groups = "avb_link", "avb_mdio", "avb_mii"; 1686be33864SEmmanuel Vadot function = "avb"; 1696be33864SEmmanuel Vadot }; 1706be33864SEmmanuel Vadot 1716be33864SEmmanuel Vadot pins_mdio { 1726be33864SEmmanuel Vadot groups = "avb_mdio"; 1736be33864SEmmanuel Vadot drive-strength = <24>; 1746be33864SEmmanuel Vadot }; 1756be33864SEmmanuel Vadot 1766be33864SEmmanuel Vadot pins_mii_tx { 1776be33864SEmmanuel Vadot pins = "PIN_AVB_TX_CTL", "PIN_AVB_TXC", 1786be33864SEmmanuel Vadot "PIN_AVB_TD0", "PIN_AVB_TD1", "PIN_AVB_TD2", 1796be33864SEmmanuel Vadot "PIN_AVB_TD3"; 1806be33864SEmmanuel Vadot drive-strength = <12>; 1816be33864SEmmanuel Vadot }; 1826be33864SEmmanuel Vadot }; 1836be33864SEmmanuel Vadot 1846be33864SEmmanuel Vadot keys_pins: keys { 1856be33864SEmmanuel Vadot pins = "GP_5_17", "GP_5_20", "GP_5_22", "GP_2_1"; 1866be33864SEmmanuel Vadot bias-pull-up; 1876be33864SEmmanuel Vadot }; 1886be33864SEmmanuel Vadot 1896be33864SEmmanuel Vadot sdhi0_pins: sd0 { 1906be33864SEmmanuel Vadot groups = "sdhi0_data4", "sdhi0_ctrl"; 1916be33864SEmmanuel Vadot function = "sdhi0"; 1926be33864SEmmanuel Vadot power-source = <3300>; 1936be33864SEmmanuel Vadot }; 1946be33864SEmmanuel Vadot }; 195