Debian Codegraph @

scripts/dtc/include-prefixes/arm64/rockchip/rk3588-orangepi-5-compact.dtsi

raw
1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2
3 /dts-v1/;
4
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/pinctrl/rockchip.h>
7 #include "rk3588-orangepi-5.dtsi"
8
9 / {
10 vcc5v0_usb30_otg: vcc5v0-usb30-otg-regulator {
11 compatible = "regulator-fixed";
12 enable-active-high;
13 /* USB_OTG_PWREN */
14 gpios = <&gpio4 RK_PB3 GPIO_ACTIVE_HIGH>;
15 pinctrl-names = "default";
16 pinctrl-0 = <&usb_otg_pwren>;
17 regulator-name = "vcc5v0_usb30_otg";
18 regulator-min-microvolt = <5000000>;
19 regulator-max-microvolt = <5000000>;
20 vin-supply = <&vcc5v0_sys>;
21 };
22 };
23
24 &headphone_amp {
25 /* PHONE_CTL */
26 enable-gpios = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>;
27 };
28
29 &analog_sound {
30 pinctrl-names = "default";
31 pinctrl-0 = <&hp_detect>;
32 simple-audio-card,aux-devs = <&headphone_amp>;
33 simple-audio-card,hp-det-gpios = <&gpio3 RK_PD2 GPIO_ACTIVE_HIGH>;
34
35 simple-audio-card,routing =
36 "Headphones", "LOUT1",
37 "Headphones", "ROUT1",
38 "LINPUT1", "Microphone Jack",
39 "RINPUT1", "Microphone Jack",
40 "LINPUT2", "Onboard Microphone",
41 "RINPUT2", "Onboard Microphone";
42 simple-audio-card,widgets =
43 "Microphone", "Microphone Jack",
44 "Microphone", "Onboard Microphone",
45 "Headphone", "Headphones";
46 };
47
48 &fan {
49 /* FAN_CTL_H */
50 pwms = <&pwm9 0 50000 0>;
51 };
52
53 &hym8563 {
54 interrupt-parent = <&gpio0>;
55 interrupts = <RK_PC4 IRQ_TYPE_LEVEL_LOW>;
56 pinctrl-names = "default";
57 pinctrl-0 = <&rtc_int_l>;
58 };
59
60 &led_blue_pwm {
61 /* PWM_LED1 */
62 status = "okay";
63 };
64
65 /* phy2 */
66 &pcie2x1l1 {
67 reset-gpios = <&gpio3 RK_PD4 GPIO_ACTIVE_HIGH>;
68 vpcie3v3-supply = <&vcc3v3_pcie_eth>;
69 status = "okay";
70 };
71
72 &pinctrl {
73 hym8563 {
74 rtc_int_l: hym8563-int {
75 rockchip,pins = <0 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>;
76 };
77 };
78
79 sound {
80 hp_detect: hp-detect {
81 rockchip,pins = <3 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
82 };
83 };
84
85 usb {
86 usb_host_pwren: usb-host-pwren {
87 rockchip,pins = <3 RK_PD5 RK_FUNC_GPIO &pcfg_pull_none>;
88 };
89 };
90
91 wireless-bluetooth {
92 bt_reg_on: bt-reg-on {
93 rockchip,pins = <4 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>;
94 };
95
96 bt_wake_host: bt-wake-host {
97 rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_down>;
98 };
99
100 host_wake_bt: host-wake-bt {
101 rockchip,pins = <4 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>;
102 };
103 };
104 };
105
106 &pwm4 {
107 pinctrl-names = "default";
108 pinctrl-0 = <&pwm4m0_pins>;
109 status = "okay";
110 };
111
112 &pwm5 {
113 pinctrl-names = "default";
114 pinctrl-0 = <&pwm5m1_pins>;
115 status = "okay";
116 };
117
118 &pwm9 {
119 pinctrl-names = "default";
120 pinctrl-0 = <&pwm9m2_pins>;
121 status = "okay";
122 };
123
124 &sfc {
125 pinctrl-names = "default";
126 pinctrl-0 = <&fspim2_pins>;
127 };
128
129 &u2phy0_otg {
130 phy-supply = <&vcc5v0_usb30_otg>;
131 };
132
133 &u2phy1_otg {
134 phy-supply = <&vcc5v0_usb20>;
135 };
136
137 &uart7 {
138 pinctrl-names = "default";
139 pinctrl-0 = <&uart7m0_xfer &uart7m0_ctsn &uart7m0_rtsn>;
140 uart-has-rtscts;
141 status = "okay";
142
143 bluetooth {
144 compatible = "brcm,bcm43438-bt";
145 clocks = <&hym8563>;
146 clock-names = "lpo";
147 device-wakeup-gpios = <&gpio4 RK_PC5 GPIO_ACTIVE_HIGH>;
148 interrupt-parent = <&gpio0>;
149 interrupts = <RK_PA0 IRQ_TYPE_EDGE_FALLING>;
150 interrupt-names = "host-wakeup";
151 pinctrl-names = "default";
152 pinctrl-0 = <&bt_reg_on>, <&host_wake_bt>, <&bt_wake_host>;
153 shutdown-gpios = <&gpio4 RK_PC4 GPIO_ACTIVE_HIGH>;
154 vbat-supply = <&vcc_3v3_s3>;
155 vddio-supply = <&vcc_1v8_s3>;
156 };
157 };
158
159 &usb_host0_xhci {
160 dr_mode = "host";
161 };
162
163 /* pcie eth. not a real regulator. 33VAUX */
164 &vcc3v3_pcie_eth {
165 /* Ethernet_power_en */
166 gpios = <&gpio0 RK_PD3 GPIO_ACTIVE_LOW>;
167 };
168
169 /*
170 * Represents the vcc5v0_usb20 and vcc5v0_usb30 in the schematic,
171 * both regulators share the same enable gpio
172 */
173 &vcc5v0_usb20 {
174 /* USB_HOST_PWREN */
175 gpios = <&gpio3 RK_PD5 GPIO_ACTIVE_HIGH>;
176 pinctrl-names = "default";
177 pinctrl-0 = <&usb_host_pwren>;
178 };