Skip to content

Commit fb0938d

Browse files
Yankun Zhengrkhuangtao
authored andcommitted
ARM: dts: rockchip: Modify pinctrl configuration for android things SOM.
fix the pinctrl default state is repeatedly defined between rk3229-at-gva.dts and rk3229-at-som.dtsi Change-Id: I117b3d97d446899ad7f35234df7c8dc0da60634e Signed-off-by: Yankun Zheng <zyk@rock-chips.com>
1 parent c25b644 commit fb0938d

2 files changed

Lines changed: 58 additions & 190 deletions

File tree

arch/arm/boot/dts/rk3229-at-gva.dts

Lines changed: 7 additions & 91 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
#include "rk3229-at-som.dtsi"
4646

4747
/ {
48-
model = "RK3229 ANDROID THINGS 3NOD Board";
48+
model = "RK3229 ANDROID THINGS GVA Board";
4949
compatible = "rockchip,rk3229-at-gva", "rockchip,rk3229";
5050

5151
sdio_pwrseq: sdio-pwrseq {
@@ -126,109 +126,25 @@
126126
};
127127

128128
&pinctrl {
129-
pinctrl-names = "default", "gpio_pwm0", "gpio_pwm1", "gpio_spdif", "gpio_irrx";
129+
pinctrl-names = "default";
130130
/*
131-
* sdmmc pins are defaultly set as gpio, if you want to enable
132-
* it, please remove below line.
131+
* sdmmc, pwm0, pwm2, ir, and spdif pins are defaultly set as gpio,
132+
* if you want to enable it, please remove below besides fixed_gpio.
133133
*/
134-
pinctrl-0 = <&gpio1b6_gpio &gpio1b7_gpio &gpio1c0_gpio
135-
&gpio1c1_gpio &gpio1c2_gpio &gpio1c3_gpio
136-
&gpio1c4_gpio &gpio1c5_gpio>;
137-
/*
138-
* pwm0 pins are defaultly set as gpio, if you want to enable
139-
* it, please remove below line.
140-
*/
141-
pinctrl-1 = <&gpio3c5_gpio>;
142-
/*
143-
* pwm1 pins are defaultly set as gpio, if you want to enable
144-
* it, please remove below line.
145-
*/
146-
pinctrl-2 = <&gpio1b4_gpio>;
147-
/*
148-
* spdif pins are defaultly set as gpio, if you want to enable
149-
* it, please remove below line.
150-
*/
151-
pinctrl-3 = <&gpio3d7_gpio>;
152-
/*
153-
* ir_rx pins are defaultly set as gpio, if you want to enable
154-
* it, please remove below line.
155-
*/
156-
pinctrl-4 = <&gpio1b3_gpio>;
157-
158-
ir-rx-gpio {
159-
gpio1b3_gpio: gpio1b3-gpio {
160-
rockchip,pins =
161-
<1 11 RK_FUNC_GPIO &pcfg_pull_up>;
162-
};
163-
};
134+
pinctrl-0 = <&sdmmc_gpio &pwm0_gpio &pwm2_gpio
135+
&ir_gpio &spdif_gpio &fixed_gpio>;
164136

165137
keys {
166138
pwr_key: pwr-key {
167139
rockchip,pins = <3 23 RK_FUNC_GPIO &pcfg_pull_down>;
168140
};
169141
};
170142

171-
pwm0-gpio {
172-
gpio3c5_gpio: gpio3c5-gpio {
173-
rockchip,pins =
174-
<3 21 RK_FUNC_GPIO &pcfg_pull_down>;
175-
};
176-
};
177-
178-
pwm2-gpio {
179-
gpio1b4_gpio: gpio1b4-gpio {
180-
rockchip,pins =
181-
<1 12 RK_FUNC_GPIO &pcfg_pull_up>;
182-
};
183-
};
184-
185143
sdio-pwrseq {
186144
wifi_enable_h: wifi-enable-h {
187145
rockchip,pins = <3 15 RK_FUNC_GPIO &pcfg_pull_none>;
188146
};
189147
};
190-
191-
sdmmc-gpio {
192-
gpio1b6_gpio: gpio1b6-gpio {
193-
rockchip,pins =
194-
<1 14 RK_FUNC_GPIO &pcfg_pull_none>;
195-
};
196-
gpio1b7_gpio: gpio1b7-gpio {
197-
rockchip,pins =
198-
<1 15 RK_FUNC_GPIO &pcfg_pull_up>;
199-
};
200-
gpio1c0_gpio: gpio1c0-gpio {
201-
rockchip,pins =
202-
<1 16 RK_FUNC_GPIO &pcfg_pull_none>;
203-
};
204-
gpio1c1_gpio: gpio1c1-gpio {
205-
rockchip,pins =
206-
<1 17 RK_FUNC_GPIO &pcfg_pull_up>;
207-
};
208-
gpio1c2_gpio: gpio1c2-gpio {
209-
rockchip,pins =
210-
<1 18 RK_FUNC_GPIO &pcfg_pull_up>;
211-
};
212-
gpio1c3_gpio: gpio1c3-gpio {
213-
rockchip,pins =
214-
<1 19 RK_FUNC_GPIO &pcfg_pull_up>;
215-
};
216-
gpio1c4_gpio: gpio1c4-gpio {
217-
rockchip,pins =
218-
<1 20 RK_FUNC_GPIO &pcfg_pull_up>;
219-
};
220-
gpio1c5_gpio: gpio1c5-gpio {
221-
rockchip,pins =
222-
<1 21 RK_FUNC_GPIO &pcfg_pull_up>;
223-
};
224-
};
225-
226-
spdif-out-gpio {
227-
gpio3d7_gpio: gpio3d7-gpio {
228-
rockchip,pins =
229-
<3 31 RK_FUNC_GPIO &pcfg_pull_down>;
230-
};
231-
};
232148
};
233149

234150
&sdio {
@@ -241,7 +157,7 @@
241157

242158
/*
243159
* If sdmmc is enabled on hardware, set status to okay.
244-
* and remove the according pinctrl nodes above.
160+
* and remove the sdmmc_gpio from pinctrl-0 above.
245161
*/
246162
&sdmmc {
247163
bus-width = <4>;

arch/arm/boot/dts/rk3229-at-som.dtsi

Lines changed: 51 additions & 99 deletions
Original file line numberDiff line numberDiff line change
@@ -137,113 +137,65 @@
137137
};
138138

139139
&pinctrl {
140-
pinctrl-names = "default";
141-
142-
pinctrl-0 = <&fixed0_gpio &fixed1_gpio &fixed2_gpio
143-
&fixed3_gpio &fixed4_gpio &fixed5_gpio
144-
&fixed6_gpio &fixed7_gpio &fixed8_gpio
145-
&fixed9_gpio &fixed10_gpio &fixed11_gpio
146-
&fixed12_gpio &fixed13_gpio &fixed14_gpio
147-
&fixed15_gpio &fixed16_gpio &fixed17_gpio
148-
&fixed18_gpio &fixed19_gpio &fixed20_gpio
149-
&fixed21_gpio &fixed22_gpio>;
150-
151-
fixed_gpio {
152-
fixed0_gpio: gpio2c3-gpio {
153-
rockchip,pins =
154-
<2 19 RK_FUNC_GPIO &pcfg_pull_down>;
155-
};
156-
fixed1_gpio: gpio2c2-gpio {
157-
rockchip,pins =
158-
<2 18 RK_FUNC_GPIO &pcfg_pull_down>;
159-
};
160-
fixed2_gpio: gpio2c1-gpio {
161-
rockchip,pins =
162-
<2 17 RK_FUNC_GPIO &pcfg_pull_down>;
163-
};
164-
fixed3_gpio: gpio2c0-gpio {
165-
rockchip,pins =
166-
<2 16 RK_FUNC_GPIO &pcfg_pull_down>;
167-
};
168-
fixed4_gpio: gpio2b7-gpio {
169-
rockchip,pins =
170-
<2 15 RK_FUNC_GPIO &pcfg_pull_down>;
171-
};
172-
fixed5_gpio: gpio2b6-gpio {
173-
rockchip,pins =
174-
<2 14 RK_FUNC_GPIO &pcfg_pull_down>;
175-
};
176-
fixed6_gpio: gpio2b5-gpio {
177-
rockchip,pins =
178-
<2 13 RK_FUNC_GPIO &pcfg_pull_down>;
179-
};
180-
fixed7_gpio: gpio2b4-gpio {
181-
rockchip,pins =
182-
<2 12 RK_FUNC_GPIO &pcfg_pull_down>;
183-
};
184-
fixed8_gpio: gpio2b3-gpio {
185-
rockchip,pins =
186-
<2 11 RK_FUNC_GPIO &pcfg_pull_down>;
187-
};
188-
fixed9_gpio: gpio2b2-gpio {
189-
rockchip,pins =
190-
<2 10 RK_FUNC_GPIO &pcfg_pull_down>;
191-
};
192-
fixed10_gpio: gpio2b1-gpio {
193-
rockchip,pins =
194-
<2 9 RK_FUNC_GPIO &pcfg_pull_down>;
195-
};
196-
fixed11_gpio: gpio2b0-gpio {
197-
rockchip,pins =
198-
<2 8 RK_FUNC_GPIO &pcfg_pull_down>;
199-
};
200-
fixed12_gpio: gpio1a7-gpio {
201-
rockchip,pins =
202-
<1 7 RK_FUNC_GPIO &pcfg_pull_down>;
203-
};
204-
fixed13_gpio: gpio1a3-gpio {
205-
rockchip,pins =
206-
<1 3 RK_FUNC_GPIO &pcfg_pull_down>;
207-
};
208-
fixed14_gpio: gpio1a0-gpio {
209-
rockchip,pins =
210-
<1 0 RK_FUNC_GPIO &pcfg_pull_down>;
140+
sdmmc {
141+
sdmmc_gpio: sdmmc-gpio {
142+
rockchip,pins = <1 14 RK_FUNC_GPIO &pcfg_pull_none>,
143+
<1 15 RK_FUNC_GPIO &pcfg_pull_up>,
144+
<1 16 RK_FUNC_GPIO &pcfg_pull_none>,
145+
<1 17 RK_FUNC_GPIO &pcfg_pull_up>,
146+
<1 18 RK_FUNC_GPIO &pcfg_pull_up>,
147+
<1 19 RK_FUNC_GPIO &pcfg_pull_up>,
148+
<1 20 RK_FUNC_GPIO &pcfg_pull_up>,
149+
<1 21 RK_FUNC_GPIO &pcfg_pull_up>;
211150
};
212-
fixed15_gpio: gpio1b0-gpio {
213-
rockchip,pins =
214-
<1 8 RK_FUNC_GPIO &pcfg_pull_up>;
215-
};
216-
fixed16_gpio: gpio0c1-gpio {
217-
rockchip,pins =
218-
<0 17 RK_FUNC_GPIO &pcfg_pull_up>;
219-
};
220-
fixed17_gpio: gpio0d0-gpio {
221-
rockchip,pins =
151+
};
152+
153+
fixed_io {
154+
fixed_gpio: fixed-gpio {
155+
rockchip,pins = <2 19 RK_FUNC_GPIO &pcfg_pull_none>,
156+
<2 18 RK_FUNC_GPIO &pcfg_pull_none>,
157+
<2 17 RK_FUNC_GPIO &pcfg_pull_none>,
158+
<2 16 RK_FUNC_GPIO &pcfg_pull_none>,
159+
<2 15 RK_FUNC_GPIO &pcfg_pull_none>,
160+
<2 14 RK_FUNC_GPIO &pcfg_pull_none>,
161+
<2 13 RK_FUNC_GPIO &pcfg_pull_none>,
162+
<2 12 RK_FUNC_GPIO &pcfg_pull_none>,
163+
<2 11 RK_FUNC_GPIO &pcfg_pull_none>,
164+
<2 10 RK_FUNC_GPIO &pcfg_pull_none>,
165+
<2 9 RK_FUNC_GPIO &pcfg_pull_none>,
166+
<2 8 RK_FUNC_GPIO &pcfg_pull_up>,
167+
<1 7 RK_FUNC_GPIO &pcfg_pull_none>,
168+
<1 3 RK_FUNC_GPIO &pcfg_pull_none>,
169+
<1 0 RK_FUNC_GPIO &pcfg_pull_none>,
170+
<1 8 RK_FUNC_GPIO &pcfg_pull_up>,
171+
<0 17 RK_FUNC_GPIO &pcfg_pull_up>,
222172
<0 24 RK_FUNC_GPIO &pcfg_pull_up>;
223173
};
224-
fixed18_gpio: gpio3c4-gpio {
225-
rockchip,pins =
226-
<3 20 RK_FUNC_GPIO &pcfg_pull_down>;
227-
};
228-
fixed19_gpio: gpio2d1-gpio {
229-
rockchip,pins =
230-
<2 25 RK_FUNC_GPIO &pcfg_pull_up>;
231-
};
232-
fixed20_gpio: gpio2d0-gpio {
233-
rockchip,pins =
234-
<2 24 RK_FUNC_GPIO &pcfg_pull_up>;
235-
};
236-
fixed21_gpio: gpio2c6-gpio {
237-
rockchip,pins =
238-
<2 22 RK_FUNC_GPIO &pcfg_pull_up>;
174+
};
175+
176+
ir {
177+
ir_gpio: ir-gpio {
178+
rockchip,pins = <1 11 RK_FUNC_GPIO &pcfg_pull_up>;
239179
};
240-
fixed22_gpio: gpio2c7-gpio {
241-
rockchip,pins =
242-
<2 23 RK_FUNC_GPIO &pcfg_pull_up>;
180+
};
181+
182+
pwm0 {
183+
pwm0_gpio: pwm0-gpio {
184+
rockchip,pins = <3 21 RK_FUNC_GPIO &pcfg_pull_none>;
243185
};
186+
};
244187

188+
pwm2 {
189+
pwm2_gpio: pwm2-gpio {
190+
rockchip,pins = <1 12 RK_FUNC_GPIO &pcfg_pull_up>;
191+
};
245192
};
246193

194+
spdif {
195+
spdif_gpio: spdif-gpio {
196+
rockchip,pins = <3 31 RK_FUNC_GPIO &pcfg_pull_none>;
197+
};
198+
};
247199
};
248200

249201
&rockchip_suspend {

0 commit comments

Comments
 (0)