Skip to content

Commit b046e01

Browse files
committed
Update Aiot-rk3588a device tree: remove unused includes, update LED GPIO, and add USB Type-C and regulator configurations
1 parent 3bc07c7 commit b046e01

File tree

1 file changed

+225
-16
lines changed

1 file changed

+225
-16
lines changed

patch/kernel/rk35xx-vendor-6.1/dt/rk3588-aiot-rk3588a.dts

Lines changed: 225 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
/dts-v1/;
88

99
#include "rk3588-evb7-lp4.dtsi"
10-
#include "rk3588-evb7-imx415.dtsi"
1110
#include "rk3588-linux.dtsi"
1211

1312
/ {
@@ -21,21 +20,11 @@
2120
leds {
2221
compatible = "gpio-leds";
2322
work {
24-
gpios = <&gpio4 RK_PB7 GPIO_ACTIVE_HIGH>;
23+
gpios = <&gpio4 RK_PA5 GPIO_ACTIVE_HIGH>;
2524
linux,default-trigger = "heartbeat";
2625
};
2726
};
28-
29-
30-
mcuinf {
31-
compatible = "smdtmcu,STM8S00K3";
32-
status = "okay";
33-
reg = <0x62>;
34-
#pwm-cells = <2>;
35-
/* MCU interrupt pin: GPIO0_B0 */
36-
int-gpio = <&gpio0 RK_PB0 GPIO_ACTIVE_HIGH>;
37-
};
38-
27+
/*
3928
adc-keys {
4029
compatible = "adc-keys";
4130
io-channels = <0x1d5 0x01>;
@@ -73,7 +62,7 @@
7362
linux,code = <0x73>;
7463
press-threshold-microvolt = <0x30d40>;
7564
};
76-
};
65+
};*/
7766

7867
panel-edp0 {
7968
compatible = "simple-panel";
@@ -114,19 +103,239 @@
114103
regulator-name = "vcc3v3_lcd";
115104
vin-supply = <&vcc_3v3_s0>;
116105
};
106+
107+
vbus5v0_typec: vbus5v0-typec {
108+
compatible = "regulator-fixed";
109+
regulator-name = "vbus5v0_typec";
110+
regulator-min-microvolt = <5000000>;
111+
regulator-max-microvolt = <5000000>;
112+
enable-active-high;
113+
gpio = <&gpio4 RK_PA1 GPIO_ACTIVE_HIGH>;
114+
vin-supply = <&vcc5v0_host>;
115+
pinctrl-names = "default";
116+
pinctrl-0 = <&typec5v_pwren>;
117+
};
118+
119+
vcc5v0_peripherals:vcc5v0-peripherals {
120+
compatible = "regulator-fixed";
121+
regulator-name = "vcc5v0_peripherals";
122+
regulator-boot-on;
123+
regulator-always-on;
124+
regulator-min-microvolt = <0x4c4b40>;
125+
regulator-max-microvolt = <0x4c4b40>;
126+
enable-active-high;
127+
gpio = <&gpio3 RK_PD5 GPIO_ACTIVE_HIGH>;
128+
vin-supply = <&vcc5v0_usb>;
129+
pinctrl-names = "default";
130+
pinctrl-0 = <&vcc5v0_peripherals_en>;
131+
};
132+
133+
vcc5v0_usb:vcc5v0-usb {
134+
compatible = "regulator-fixed";
135+
regulator-name = "vcc5v0_usb";
136+
regulator-always-on;
137+
regulator-boot-on;
138+
regulator-min-microvolt = <0x4c4b40>;
139+
regulator-max-microvolt = <0x4c4b40>;
140+
vin-supply = <&vcc5v0_usbdcin>;
141+
};
142+
143+
vcc5v0_usbdcin:vcc5v0-usbdcin {
144+
compatible = "regulator-fixed";
145+
regulator-name = "vcc5v0_usbdcin";
146+
regulator-always-on;
147+
regulator-boot-on;
148+
regulator-min-microvolt = <0x4c4b40>;
149+
regulator-max-microvolt = <0x4c4b40>;
150+
vin-supply = <&vcc12v_dcin>;
151+
};
152+
153+
vcc12v_dcin:vcc12v-dcin {
154+
compatible = "regulator-fixed";
155+
regulator-name = "vcc12v_dcin";
156+
regulator-always-on;
157+
regulator-boot-on;
158+
regulator-min-microvolt = <0xb71b00>;
159+
regulator-max-microvolt = <0xb71b00>;
160+
};
117161
};
118162

119163
&pinctrl {
120164
mcu {
121-
mcum0-pins {
165+
mcum0_pins:mcum0-pins {
122166
rockchip,pins = <0x04 0x1c 0x05 0x1a3 0x04 0x1d 0x05 0x1a3>;
123167
};
124168

125-
mcum1-pins {
169+
mcum1_pins:mcum1-pins {
126170
rockchip,pins = <0x03 0x1c 0x06 0x1a3 0x03 0x1d 0x06 0x1a3>;
127171
};
128172
};
129173

174+
usb-typec {
175+
usbc0_int:usbc0-int {
176+
rockchip,pins = <0x00 0x1b 0x00 0x1a8>;
177+
};
178+
179+
typec5v_pwren:typec5v-pwren {
180+
rockchip,pins = <0x04 0x01 0x00 0x1a3>;
181+
};
182+
};
183+
184+
usb {
185+
vcc5v0_host_en:vcc5v0-host-en {
186+
rockchip,pins = <0x04 0x08 0x00 0x1a3>;
187+
};
188+
189+
vcc5v0_peripherals_en:vcc5v0-peripherals-en {
190+
rockchip,pins = <0x03 0x1d 0x00 0x1a3>;
191+
};
192+
};
193+
194+
};
195+
196+
&i2c6 {
197+
status = "okay";
198+
pinctrl-names = "default";
199+
pinctrl-0 = <&i2c6m0_xfer>;
200+
201+
nca9555: nca9555@20 {
202+
reg = <0x20>;
203+
compatible = "novosense,nca9555";
204+
status = "okay";
205+
gpio-controller;
206+
#gpio-cells = <2>;
207+
ngpios = <16>;
208+
//可选:如果连接了 INT 引脚
209+
//interrupt-parent = <&gpio1>;
210+
//interrupts = <61 IRQ_TYPE_EDGE_FALLING>;
211+
};
212+
213+
mcuinf: mcuinf@62 {
214+
compatible = "smdtmcu,STM8S00K3";
215+
status = "okay";
216+
reg = <0x62>;
217+
#pwm-cells = <2>;
218+
/* MCU interrupt pin: GPIO0_B0 */
219+
int-gpio = <&gpio0 RK_PB0 GPIO_ACTIVE_HIGH>;
220+
};
221+
222+
usbc0: fusb302@22 {
223+
compatible = "fcs,fusb302";
224+
reg = <0x22>;
225+
interrupt-parent = <&gpio0>;
226+
interrupts = <RK_PD3 IRQ_TYPE_LEVEL_LOW>;
227+
int-n-gpios = <&gpio0 RK_PD3 GPIO_ACTIVE_LOW>;
228+
pinctrl-names = "default";
229+
pinctrl-0 = <&usbc0_int>;
230+
vbus-supply = <&vbus5v0_typec>;
231+
status = "okay";
232+
233+
ports {
234+
#address-cells = <1>;
235+
#size-cells = <0>;
236+
237+
port@0 {
238+
reg = <0>;
239+
usbc0_role_sw: endpoint@0 {
240+
remote-endpoint = <&dwc3_0_role_switch>;
241+
};
242+
};
243+
};
244+
245+
usb_con: connector {
246+
compatible = "usb-c-connector";
247+
label = "USB-C";
248+
data-role = "dual";
249+
power-role = "dual";
250+
try-power-role = "sink";
251+
op-sink-microwatt = <1000000>;
252+
sink-pdos =
253+
<PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)>;
254+
source-pdos =
255+
<PDO_FIXED(5000, 2000, PDO_FIXED_USB_COMM)>;
256+
257+
altmodes {
258+
#address-cells = <1>;
259+
#size-cells = <0>;
260+
261+
altmode@0 {
262+
reg = <0>;
263+
svid = <0xff01>;
264+
vdo = <0xffffffff>;
265+
};
266+
};
267+
268+
ports {
269+
#address-cells = <1>;
270+
#size-cells = <0>;
271+
272+
port@0 {
273+
reg = <0>;
274+
usbc0_orien_sw: endpoint {
275+
remote-endpoint = <&usbdp_phy0_orientation_switch>;
276+
};
277+
};
278+
279+
port@1 {
280+
reg = <1>;
281+
dp_altmode_mux: endpoint {
282+
remote-endpoint = <&usbdp_phy0_dp_altmode_mux>;
283+
};
284+
};
285+
};
286+
};
287+
};
288+
289+
};
290+
291+
&usbdrd_dwc3_0 {
292+
dr_mode = "otg";
293+
usb-role-switch;
294+
status = "okay";
295+
296+
port {
297+
#address-cells = <1>;
298+
#size-cells = <0>;
299+
dwc3_0_role_switch: endpoint@0 {
300+
reg = <0>;
301+
remote-endpoint = <&usbc0_role_sw>;
302+
};
303+
};
304+
};
305+
306+
&usbdp_phy0 {
307+
orientation-switch;
308+
rockchip,dp-lane-mux = <0 1 2 3 >;
309+
svid = <0xff01>;
310+
sbu1-dc-gpios = <&gpio4 RK_PA6 GPIO_ACTIVE_HIGH>;
311+
sbu2-dc-gpios = <&gpio4 RK_PA7 GPIO_ACTIVE_HIGH>;
312+
status = "okay";
313+
314+
port {
315+
#address-cells = <1>;
316+
#size-cells = <0>;
317+
usbdp_phy0_orientation_switch: endpoint@0 {
318+
reg = <0>;
319+
remote-endpoint = <&usbc0_orien_sw>;
320+
};
321+
322+
usbdp_phy0_dp_altmode_mux: endpoint@1 {
323+
reg = <1>;
324+
remote-endpoint = <&dp_altmode_mux>;
325+
};
326+
};
327+
};
328+
329+
&usbdp_phy0_dp {
330+
status = "okay";
331+
};
332+
333+
&usbdp_phy0_u3 {
334+
status = "okay";
335+
};
336+
337+
&hym8563 {
338+
status = "disabled";
130339
};
131340

132341
&dp0 {

0 commit comments

Comments
 (0)