1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
4 $id: http://devicetree.org/schemas/pinctrl/pinctrl-mt8186.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Mediatek MT8186 Pin Controller
10 - Sean Wang <sean.wang@mediatek.com>
13 The Mediatek's Pin controller is used to control SoC pins.
17 const: mediatek,mt8186-pinctrl
23 Number of cells in GPIO specifier. Since the generic GPIO binding is used,
24 the amount of cells must be specified as 2. See the below
25 mentioned gpio binding representation for description of particular cells.
35 Physical address base for gpio base registers. There are 8 different GPIO
36 physical address base in mt8186.
41 Gpio base register names.
52 interrupt-controller: true
58 description: The interrupt outputs to sysirq
61 mediatek,rsel-resistance-in-si-unit:
64 Identifying i2c pins pull up/down type which is RSEL. It can support
65 RSEL define or si unit value(ohm) to set different resistance.
67 # PIN CONFIGURATION NODES
71 additionalProperties: false
75 additionalProperties: false
77 A pinctrl node should contain at least one subnodes representing the
78 pinctrl groups available on the machine. Each subnode will list the
79 pins it needs, and how they should be configured, with regard to muxer
80 configuration, pullups, drive strength, input enable/disable and
82 An example of using macro:
84 /* GPIO0 set as multifunction GPIO0 */
87 pinmux = <PINMUX_GPIO0__FUNC_GPIO0>;
90 /* GPIO128 set as multifunction SDA0 */
93 pinmux = <PINMUX_GPIO128__FUNC_SDA0>;
97 $ref: "pinmux-node.yaml"
102 Integer array, represents gpio pin number and mux setting.
103 Supported pin number and mux varies for different SoCs, and are
104 defined as macros in dt-bindings/pinctrl/<soc>-pinfunc.h
108 enum: [2, 4, 6, 8, 10, 12, 14, 16]
110 drive-strength-microamp:
111 enum: [125, 250, 500, 1000]
116 - enum: [100, 101, 102, 103]
117 description: mt8186 pull down PUPD/R0/R1 type define value.
118 - enum: [200, 201, 202, 203]
119 description: mt8186 pull down RSEL type define value.
120 - enum: [75000, 5000]
121 description: mt8186 pull down RSEL type si unit value(ohm).
123 For pull down type is normal, it don't need add RSEL & R1R0 define
124 and resistance value.
125 For pull down type is PUPD/R0/R1 type, it can add R1R0 define to
126 set different resistance. It can support "MTK_PUPD_SET_R1R0_00" &
127 "MTK_PUPD_SET_R1R0_01" & "MTK_PUPD_SET_R1R0_10" &
128 "MTK_PUPD_SET_R1R0_11" define in mt8186.
129 For pull down type is RSEL, it can add RSEL define & resistance
130 value(ohm) to set different resistance by identifying property
131 "mediatek,rsel-resistance-in-si-unit".
132 It can support "MTK_PULL_SET_RSEL_000" & "MTK_PULL_SET_RSEL_001"
133 & "MTK_PULL_SET_RSEL_010" & "MTK_PULL_SET_RSEL_011"
134 define in mt8186. It can also support resistance value(ohm)
135 "75000" & "5000" in mt8186.
136 An example of using RSEL define:
140 pinmux = <PINMUX_GPIO128__FUNC_SDA0>;
141 bias-pull-down = <MTK_PULL_SET_RSEL_001>;
145 An example of using si unit resistance value(ohm):
147 mediatek,rsel-resistance-in-si-unit;
152 pinmux = <PINMUX_GPIO128__FUNC_SDA0>;
153 bias-pull-down = <75000>;
161 - enum: [100, 101, 102, 103]
162 description: mt8186 pull up PUPD/R0/R1 type define value.
163 - enum: [200, 201, 202, 203]
164 description: mt8186 pull up RSEL type define value.
165 - enum: [1000, 5000, 10000, 75000]
166 description: mt8186 pull up RSEL type si unit value(ohm).
168 For pull up type is normal, it don't need add RSEL & R1R0 define
169 and resistance value.
170 For pull up type is PUPD/R0/R1 type, it can add R1R0 define to
171 set different resistance. It can support "MTK_PUPD_SET_R1R0_00" &
172 "MTK_PUPD_SET_R1R0_01" & "MTK_PUPD_SET_R1R0_10" &
173 "MTK_PUPD_SET_R1R0_11" define in mt8186.
174 For pull up type is RSEL, it can add RSEL define & resistance
175 value(ohm) to set different resistance by identifying property
176 "mediatek,rsel-resistance-in-si-unit".
177 It can support "MTK_PULL_SET_RSEL_000" & "MTK_PULL_SET_RSEL_001"
178 & "MTK_PULL_SET_RSEL_010" & "MTK_PULL_SET_RSEL_011"
179 define in mt8186. It can also support resistance value(ohm)
180 "1000" & "5000" & "10000" & "75000" in mt8186.
181 An example of using si unit resistance value(ohm):
183 mediatek,rsel-resistance-in-si-unit;
188 pinmux = <PINMUX_GPIO128__FUNC_SDA0>;
189 bias-pull-up = <1000>;
204 input-schmitt-enable: true
206 input-schmitt-disable: true
215 - interrupt-controller
221 additionalProperties: false
225 #include <dt-bindings/pinctrl/mt8186-pinfunc.h>
226 #include <dt-bindings/interrupt-controller/arm-gic.h>
228 pio: pinctrl@10005000 {
229 compatible = "mediatek,mt8186-pinctrl";
230 reg = <0x10005000 0x1000>,
238 reg-names = "iocfg0", "iocfg_lt", "iocfg_lm",
239 "iocfg_lb", "iocfg_bl", "iocfg_rb",
243 gpio-ranges = <&pio 0 0 185>;
244 interrupt-controller;
245 interrupts = <GIC_SPI 186 IRQ_TYPE_LEVEL_HIGH 0>;
246 #interrupt-cells = <2>;
250 pinmux = <PINMUX_GPIO0__FUNC_GPIO0>;
257 pinmux = <PINMUX_GPIO0__FUNC_SPI0_CLK_B>,
258 <PINMUX_GPIO1__FUNC_SPI0_CSB_B>,
259 <PINMUX_GPIO2__FUNC_SPI0_MO_B>;
263 pinmux = <PINMUX_GPIO3__FUNC_SPI0_MI_B>;
270 pinmux = <PINMUX_GPIO127__FUNC_SCL0>,
271 <PINMUX_GPIO128__FUNC_SDA0>;
272 bias-pull-up = <MTK_PULL_SET_RSEL_001>;
273 drive-strength-microamp = <1000>;