]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
arm64: dts: allwinner: a64: NanoPi-A64: Add Ethernet
authorAndre Przywara <andre.przywara@arm.com>
Mon, 30 Jul 2018 12:31:35 +0000 (13:31 +0100)
committerChen-Yu Tsai <wens@csie.org>
Mon, 27 Aug 2018 07:42:56 +0000 (15:42 +0800)
The NanoPi-A64 has the usual Realtek Gbit PHY connected to the EMAC,
so add the respective nodes to the DT. The PHY is powered by the
VDD_SYS_3.3V line, which is always on.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Acked-by: Maxime Ripard <maxime.ripard@bootlin.com>
Signed-off-by: Chen-Yu Tsai <wens@csie.org>
arch/arm64/boot/dts/allwinner/sun50i-a64-nanopi-a64.dts

index 5caba225b4f78760b4d8d316ae706daab0fa44e5..1eba1324e5b94e1455eaad669d006c6f841c40c0 100644 (file)
@@ -51,6 +51,7 @@ / {
        compatible = "friendlyarm,nanopi-a64", "allwinner,sun50i-a64";
 
        aliases {
+               ethernet0 = &emac;
                serial0 = &uart0;
        };
 
@@ -67,6 +68,15 @@ &ehci1 {
        status = "okay";
 };
 
+&emac {
+       pinctrl-names = "default";
+       pinctrl-0 = <&rgmii_pins>;
+       phy-mode = "rgmii";
+       phy-handle = <&ext_rgmii_phy>;
+       phy-supply = <&reg_dcdc1>;
+       status = "okay";
+};
+
 /* i2c1 connected with gpio headers like pine64, bananapi */
 &i2c1 {
        pinctrl-names = "default";
@@ -78,6 +88,13 @@ &i2c1_pins {
        bias-pull-up;
 };
 
+&mdio {
+       ext_rgmii_phy: ethernet-phy@1 {
+               compatible = "ethernet-phy-ieee802.3-c22";
+               reg = <7>;
+       };
+};
+
 &mmc0 {
        pinctrl-names = "default";
        pinctrl-0 = <&mmc0_pins>;