1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
4 $id: http://devicetree.org/schemas/pinctrl/mediatek,mt8195-pinctrl.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: MediaTek MT8195 Pin Controller
10 - Sean Wang <sean.wang@mediatek.com>
13 The MediaTek's MT8195 Pin controller is used to control SoC pins.
17 const: mediatek,mt8195-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 mentioned gpio
25 binding representation for description of particular cells.
29 description: GPIO valid number range.
36 Physical address base for GPIO base registers. There are 8 GPIO physical
37 address base in mt8195.
42 GPIO base register names.
45 interrupt-controller: true
51 description: The interrupt outputs to sysirq.
54 mediatek,rsel-resistance-in-si-unit:
57 Identifying i2c pins pull up/down type which is RSEL. It can support RSEL
58 define or si unit value(ohm) to set different resistance.
60 # PIN CONFIGURATION NODES
64 additionalProperties: false
68 additionalProperties: false
70 A pinctrl node should contain at least one subnodes representing the
71 pinctrl groups available on the machine. Each subnode will list the
72 pins it needs, and how they should be configured, with regard to muxer
73 configuration, pullups, drive strength, input enable/disable and input
75 An example of using macro:
77 /* GPIO0 set as multifunction GPIO0 */
80 pinmux = <PINMUX_GPIO0__FUNC_GPIO0>;
83 /* GPIO8 set as multifunction SDA0 */
86 pinmux = <PINMUX_GPIO8__FUNC_SDA0>;
90 $ref: pinmux-node.yaml
95 Integer array, represents gpio pin number and mux setting.
96 Supported pin number and mux varies for different SoCs, and are
97 defined as macros in dt-bindings/pinctrl/<soc>-pinfunc.h directly.
100 enum: [2, 4, 6, 8, 10, 12, 14, 16]
102 drive-strength-microamp:
103 enum: [125, 250, 500, 1000]
108 - enum: [100, 101, 102, 103]
109 description: mt8195 pull down PUPD/R0/R1 type define value.
110 - enum: [200, 201, 202, 203, 204, 205, 206, 207]
111 description: mt8195 pull down RSEL type define value.
112 - enum: [75000, 5000]
113 description: mt8195 pull down RSEL type si unit value(ohm).
115 For pull down type is normal, it don't need add RSEL & R1R0 define
116 and resistance value.
117 For pull down type is PUPD/R0/R1 type, it can add R1R0 define to
118 set different resistance. It can support "MTK_PUPD_SET_R1R0_00" &
119 "MTK_PUPD_SET_R1R0_01" & "MTK_PUPD_SET_R1R0_10" &
120 "MTK_PUPD_SET_R1R0_11" define in mt8195.
121 For pull down type is RSEL, it can add RSEL define & resistance
122 value(ohm) to set different resistance by identifying property
123 "mediatek,rsel-resistance-in-si-unit".
124 It can support "MTK_PULL_SET_RSEL_000" & "MTK_PULL_SET_RSEL_001"
125 & "MTK_PULL_SET_RSEL_010" & "MTK_PULL_SET_RSEL_011"
126 & "MTK_PULL_SET_RSEL_100" & "MTK_PULL_SET_RSEL_101"
127 & "MTK_PULL_SET_RSEL_110" & "MTK_PULL_SET_RSEL_111"
128 define in mt8195. It can also support resistance value(ohm)
129 "75000" & "5000" in mt8195.
131 An example of using RSEL define:
135 pinmux = <PINMUX_GPIO8__FUNC_SDA0>;
136 bias-pull-down = <MTK_PULL_SET_RSEL_001>;
140 An example of using si unit resistance value(ohm):
142 mediatek,rsel-resistance-in-si-unit;
147 pinmux = <PINMUX_GPIO8__FUNC_SDA0>;
148 bias-pull-down = <75000>;
156 - enum: [100, 101, 102, 103]
157 description: mt8195 pull up PUPD/R0/R1 type define value.
158 - enum: [200, 201, 202, 203, 204, 205, 206, 207]
159 description: mt8195 pull up RSEL type define value.
160 - enum: [1000, 1500, 2000, 3000, 4000, 5000, 10000, 75000]
161 description: mt8195 pull up RSEL type si unit value(ohm).
163 For pull up type is normal, it don't need add RSEL & R1R0 define
164 and resistance value.
165 For pull up type is PUPD/R0/R1 type, it can add R1R0 define to
166 set different resistance. It can support "MTK_PUPD_SET_R1R0_00" &
167 "MTK_PUPD_SET_R1R0_01" & "MTK_PUPD_SET_R1R0_10" &
168 "MTK_PUPD_SET_R1R0_11" define in mt8195.
169 For pull up type is RSEL, it can add RSEL define & resistance
170 value(ohm) to set different resistance by identifying property
171 "mediatek,rsel-resistance-in-si-unit".
172 It can support "MTK_PULL_SET_RSEL_000" & "MTK_PULL_SET_RSEL_001"
173 & "MTK_PULL_SET_RSEL_010" & "MTK_PULL_SET_RSEL_011"
174 & "MTK_PULL_SET_RSEL_100" & "MTK_PULL_SET_RSEL_101"
175 & "MTK_PULL_SET_RSEL_110" & "MTK_PULL_SET_RSEL_111"
176 define in mt8195. It can also support resistance value(ohm) "1000"
177 & "1500" & "2000" & "3000" & "4000" & "5000" & "10000" & "75000"
179 An example of using RSEL define:
183 pinmux = <PINMUX_GPIO8__FUNC_SDA0>;
184 bias-pull-up = <MTK_PULL_SET_RSEL_001>;
188 An example of using si unit resistance value(ohm):
190 mediatek,rsel-resistance-in-si-unit;
195 pinmux = <PINMUX_GPIO8__FUNC_SDA0>;
196 bias-pull-up = <1000>;
211 input-schmitt-enable: true
213 input-schmitt-disable: true
219 - $ref: pinctrl.yaml#
225 - interrupt-controller
231 additionalProperties: false
235 #include <dt-bindings/pinctrl/mt8195-pinfunc.h>
236 #include <dt-bindings/interrupt-controller/arm-gic.h>
238 pio: pinctrl@10005000 {
239 compatible = "mediatek,mt8195-pinctrl";
240 reg = <0x10005000 0x1000>,
248 reg-names = "iocfg0", "iocfg_bm", "iocfg_bl",
249 "iocfg_br", "iocfg_lm", "iocfg_rb",
253 gpio-ranges = <&pio 0 0 144>;
254 interrupt-controller;
255 interrupts = <GIC_SPI 225 IRQ_TYPE_LEVEL_HIGH 0>;
256 #interrupt-cells = <2>;
260 pinmux = <PINMUX_GPIO0__FUNC_GPIO0>;
267 pinmux = <PINMUX_GPIO132__FUNC_SPIM0_CSB>,
268 <PINMUX_GPIO134__FUNC_SPIM0_MO>,
269 <PINMUX_GPIO133__FUNC_SPIM0_CLK>;
273 pinmux = <PINMUX_GPIO135__FUNC_SPIM0_MI>;
280 pinmux = <PINMUX_GPIO8__FUNC_SDA0>,
281 <PINMUX_GPIO9__FUNC_SCL0>;
283 drive-strength-microamp = <1000>;