forked from ~ljy/RK356X_SDK_RELEASE

hc
2023-12-11 6778948f9de86c3cfaf36725a7c87dcff9ba247f
kernel/arch/arm/boot/dts/sun7i-a20-orangepi.dts
....@@ -63,8 +63,6 @@
6363
6464 leds {
6565 compatible = "gpio-leds";
66
- pinctrl-names = "default";
67
- pinctrl-0 = <&led_pins_orangepi>;
6866
6967 green {
7068 label = "orangepi:green:usr";
....@@ -74,8 +72,6 @@
7472
7573 reg_gmac_3v3: gmac-3v3 {
7674 compatible = "regulator-fixed";
77
- pinctrl-names = "default";
78
- pinctrl-0 = <&gmac_power_pin_orangepi>;
7975 regulator-name = "gmac-3v3";
8076 regulator-min-microvolt = <3300000>;
8177 regulator-max-microvolt = <3300000>;
....@@ -99,20 +95,14 @@
9995
10096 &gmac {
10197 pinctrl-names = "default";
102
- pinctrl-0 = <&gmac_pins_rgmii_a>;
103
- phy = <&phy1>;
98
+ pinctrl-0 = <&gmac_rgmii_pins>;
99
+ phy-handle = <&phy1>;
104100 phy-mode = "rgmii";
105101 phy-supply = <&reg_gmac_3v3>;
106102 status = "okay";
107
-
108
- phy1: ethernet-phy@1 {
109
- reg = <1>;
110
- };
111103 };
112104
113105 &i2c0 {
114
- pinctrl-names = "default";
115
- pinctrl-0 = <&i2c0_pins_a>;
116106 status = "okay";
117107
118108 axp209: pmic@34 {
....@@ -126,13 +116,17 @@
126116
127117 &ir0 {
128118 pinctrl-names = "default";
129
- pinctrl-0 = <&ir0_rx_pins_a>;
119
+ pinctrl-0 = <&ir0_rx_pin>;
130120 status = "okay";
131121 };
132122
123
+&gmac_mdio {
124
+ phy1: ethernet-phy@1 {
125
+ reg = <1>;
126
+ };
127
+};
128
+
133129 &mmc0 {
134
- pinctrl-names = "default";
135
- pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_orangepi>;
136130 vmmc-supply = <&reg_vcc3v3>;
137131 bus-width = <4>;
138132 cd-gpios = <&pio 7 10 GPIO_ACTIVE_LOW>; /* PH10 */
....@@ -141,40 +135,6 @@
141135
142136 &otg_sram {
143137 status = "okay";
144
-};
145
-
146
-&pio {
147
- usb0_id_detect_pin: usb0_id_detect_pin@0 {
148
- pins = "PH4";
149
- function = "gpio_in";
150
- bias-pull-up;
151
- };
152
-
153
- mmc0_cd_pin_orangepi: mmc0_cd_pin@0 {
154
- pins = "PH10";
155
- function = "gpio_in";
156
- bias-pull-up;
157
- };
158
-
159
- usb2_vbus_pin_bananapro: usb2_vbus_pin@0 {
160
- pins = "PH22";
161
- function = "gpio_out";
162
- };
163
-
164
- gmac_power_pin_orangepi: gmac_power_pin@0 {
165
- pins = "PH23";
166
- function = "gpio_out";
167
- };
168
-
169
- led_pins_orangepi: led_pins@0 {
170
- pins = "PH24";
171
- function = "gpio_out";
172
- };
173
-
174
- usb1_vbus_pin_bananapro: usb1_vbus_pin@0 {
175
- pins = "PH26";
176
- function = "gpio_out";
177
- };
178138 };
179139
180140 &reg_dcdc2 {
....@@ -207,20 +167,18 @@
207167 };
208168
209169 &reg_usb1_vbus {
210
- pinctrl-0 = <&usb1_vbus_pin_bananapro>;
211170 gpio = <&pio 7 26 GPIO_ACTIVE_HIGH>; /* PH26 */
212171 status = "okay";
213172 };
214173
215174 &reg_usb2_vbus {
216
- pinctrl-0 = <&usb2_vbus_pin_bananapro>;
217175 gpio = <&pio 7 22 GPIO_ACTIVE_HIGH>; /* PH22 */
218176 status = "okay";
219177 };
220178
221179 &uart0 {
222180 pinctrl-names = "default";
223
- pinctrl-0 = <&uart0_pins_a>;
181
+ pinctrl-0 = <&uart0_pb_pins>;
224182 status = "okay";
225183 };
226184
....@@ -234,9 +192,7 @@
234192 };
235193
236194 &usbphy {
237
- pinctrl-names = "default";
238
- pinctrl-0 = <&usb0_id_detect_pin>;
239
- usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
195
+ usb0_id_det-gpios = <&pio 7 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>; /* PH4 */
240196 usb0_vbus_power-supply = <&usb_power_supply>;
241197 usb0_vbus-supply = <&reg_usb0_vbus>;
242198 usb1_vbus-supply = <&reg_usb1_vbus>;