#include "sun50i-h5.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+
/ {
model = "OrangePi PC 2";
compatible = "xunlong,orangepi-pc-2", "allwinner,sun50i-h5";
+ aliases {
+ serial0 = &uart0;
+ ethernet0 = &emac;
+ };
+
chosen {
stdout-path = "serial0:115200n8";
};
reg = <0x40000000 0x40000000>;
};
- aliases {
- serial0 = &uart0;
- ethernet0 = &emac;
- };
-
soc {
reg_vcc3v3: vcc3v3 {
compatible = "regulator-fixed";
};
};
+&ehci0 {
+ status = "okay";
+};
+
+&ehci1 {
+ status = "okay";
+};
+
+&emac {
+ pinctrl-names = "default";
+ pinctrl-0 = <&emac_rgmii_pins>;
+ phy-mode = "rgmii";
+ phy-handle = <&ext_rgmii_phy>;
+ status = "okay";
+};
+
+&external_mdio {
+ ext_rgmii_phy: ethernet-phy@1 {
+ compatible = "ethernet-phy-ieee802.3-c22";
+ reg = <1>;
+ };
+};
+
&mmc0 {
compatible = "allwinner,sun50i-h5-mmc",
"allwinner,sun50i-a64-mmc",
pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin>;
vmmc-supply = <®_vcc3v3>;
bus-width = <4>;
- cd-gpios = <&pio 5 6 0>;
+ cd-gpios = <&pio 5 6 GPIO_ACTIVE_HIGH>;
cd-inverted;
status = "okay";
};
-&uart0 {
- pinctrl-names = "default";
- pinctrl-0 = <&uart0_pins_a>;
+&ohci0 {
status = "okay";
};
-&usbphy {
+&ohci1 {
status = "okay";
};
-&ohci1 {
+&uart0 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart0_pins_a>;
status = "okay";
};
-&ehci1 {
+&usb_otg {
+ dr_mode = "otg";
status = "okay";
};
-&emac {
- pinctrl-names = "default";
- pinctrl-0 = <&emac_rgmii_pins>;
- phy-mode = "rgmii";
- phy = <&phy1>;
+&usbphy {
status = "okay";
-
- phy1: ethernet-phy@1 {
- reg = <1>;
- };
};