190 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2%YAML 1.23---4$id: http://devicetree.org/schemas/pinctrl/ingenic,pinctrl.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#6 7title: Ingenic SoCs pin controller8 9description: >10 Please refer to pinctrl-bindings.txt in this directory for details of the11 common pinctrl bindings used by client devices, including the meaning of the12 phrase "pin configuration node".13 14 For the Ingenic SoCs, pin control is tightly bound with GPIO ports. All pins15 may be used as GPIOs, multiplexed device functions are configured within the16 GPIO port configuration registers and it is typical to refer to pins using the17 naming scheme "PxN" where x is a character identifying the GPIO port with18 which the pin is associated and N is an integer from 0 to 31 identifying the19 pin within that GPIO port. For example PA0 is the first pin in GPIO port A,20 and PB31 is the last pin in GPIO port B. The JZ4730, the JZ4740, the JZ4725B,21 the X1000 and the X1830 contains 4 GPIO ports, PA to PD, for a total of 12822 pins. The X2000 and the X2100 contains 5 GPIO ports, PA to PE, for a total of23 160 pins. The JZ4750, the JZ4755 the JZ4760, the JZ4770 and the JZ4780 contains24 6 GPIO ports, PA to PF, for a total of 192 pins. The JZ4775 contains 7 GPIO25 ports, PA to PG, for a total of 224 pins.26 27maintainers:28 - Paul Cercueil <paul@crapouillou.net>29 30properties:31 compatible:32 oneOf:33 - enum:34 - ingenic,jz4730-pinctrl35 - ingenic,jz4740-pinctrl36 - ingenic,jz4725b-pinctrl37 - ingenic,jz4750-pinctrl38 - ingenic,jz4755-pinctrl39 - ingenic,jz4760-pinctrl40 - ingenic,jz4770-pinctrl41 - ingenic,jz4775-pinctrl42 - ingenic,jz4780-pinctrl43 - ingenic,x1000-pinctrl44 - ingenic,x1500-pinctrl45 - ingenic,x1830-pinctrl46 - ingenic,x2000-pinctrl47 - ingenic,x2100-pinctrl48 - items:49 - const: ingenic,jz4760b-pinctrl50 - const: ingenic,jz4760-pinctrl51 - items:52 - const: ingenic,x1000e-pinctrl53 - const: ingenic,x1000-pinctrl54 - items:55 - const: ingenic,x2000e-pinctrl56 - const: ingenic,x2000-pinctrl57 58 reg:59 maxItems: 160 61 "#address-cells":62 const: 163 64 "#size-cells":65 const: 066 67patternProperties:68 "^gpio@[0-9]$":69 type: object70 properties:71 compatible:72 enum:73 - ingenic,jz4730-gpio74 - ingenic,jz4740-gpio75 - ingenic,jz4725b-gpio76 - ingenic,jz4750-gpio77 - ingenic,jz4755-gpio78 - ingenic,jz4760-gpio79 - ingenic,jz4770-gpio80 - ingenic,jz4775-gpio81 - ingenic,jz4780-gpio82 - ingenic,x1000-gpio83 - ingenic,x1500-gpio84 - ingenic,x1830-gpio85 - ingenic,x2000-gpio86 - ingenic,x2100-gpio87 88 reg:89 items:90 - description: The GPIO bank number91 92 gpio-controller: true93 94 "#gpio-cells":95 const: 296 97 gpio-ranges:98 maxItems: 199 100 interrupt-controller: true101 102 "#interrupt-cells":103 const: 2104 description:105 Refer to ../interrupt-controller/interrupts.txt for more details.106 107 interrupts:108 maxItems: 1109 110 required:111 - compatible112 - reg113 - gpio-controller114 - "#gpio-cells"115 - interrupts116 - interrupt-controller117 - "#interrupt-cells"118 119 additionalProperties: false120 121allOf:122 - $ref: pinctrl.yaml#123 124required:125 - compatible126 - reg127 - "#address-cells"128 - "#size-cells"129 130additionalProperties:131 anyOf:132 - type: object133 allOf:134 - $ref: pincfg-node.yaml#135 - $ref: pinmux-node.yaml#136 137 properties:138 function: true139 groups: true140 pins: true141 bias-disable: true142 bias-pull-up: true143 bias-pull-down: true144 output-low: true145 output-high: true146 additionalProperties: false147 148 - type: object149 additionalProperties:150 type: object151 allOf:152 - $ref: pincfg-node.yaml#153 - $ref: pinmux-node.yaml#154 155 properties:156 function: true157 groups: true158 pins: true159 bias-disable: true160 bias-pull-up: true161 bias-pull-down: true162 output-low: true163 output-high: true164 additionalProperties: false165 166examples:167 - |168 pinctrl@10010000 {169 compatible = "ingenic,jz4770-pinctrl";170 reg = <0x10010000 0x600>;171 172 #address-cells = <1>;173 #size-cells = <0>;174 175 gpio@0 {176 compatible = "ingenic,jz4770-gpio";177 reg = <0>;178 179 gpio-controller;180 gpio-ranges = <&pinctrl 0 0 32>;181 #gpio-cells = <2>;182 183 interrupt-controller;184 #interrupt-cells = <2>;185 186 interrupt-parent = <&intc>;187 interrupts = <17>;188 };189 };190