]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ARM: dts: bcm2711-rpi-4: Enable GENET support
authorStefan Wahren <wahrenst@gmx.net>
Mon, 11 Nov 2019 19:49:26 +0000 (20:49 +0100)
committerFlorian Fainelli <f.fainelli@gmail.com>
Thu, 14 Nov 2019 20:35:58 +0000 (12:35 -0800)
This enables the Gigabit Ethernet support on the Raspberry Pi 4.
The defined PHY mode is equivalent to the default register settings
in the downstream tree.

Signed-off-by: Matthias Brugger <mbrugger@suse.com>
Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
arch/arm/boot/dts/bcm2711-rpi-4-b.dts
arch/arm/boot/dts/bcm2711.dtsi

index cccc1ccd19be534be86c2a4c6ce8238c61886d0a..1b5a835f66bd3de475e8229cc2302576f3c57b45 100644 (file)
@@ -19,6 +19,10 @@ memory@0 {
                reg = <0 0 0>;
        };
 
+       aliases {
+               ethernet0 = &genet;
+       };
+
        leds {
                act {
                        gpios = <&gpio 42 GPIO_ACTIVE_HIGH>;
@@ -97,6 +101,19 @@ &emmc2 {
        status = "okay";
 };
 
+&genet {
+       phy-handle = <&phy1>;
+       phy-mode = "rgmii-rxid";
+       status = "okay";
+};
+
+&genet_mdio {
+       phy1: ethernet-phy@1 {
+               /* No PHY interrupt */
+               reg = <0x1>;
+       };
+};
+
 /* uart0 communicates with the BT module */
 &uart0 {
        pinctrl-names = "default";
index 34d24fe272e27676cd16ec6a099ed9d283c8b99e..961bed832755b0389b93053c7cbf2e5b4dadacbc 100644 (file)
@@ -325,6 +325,32 @@ cpu3: cpu@3 {
                        cpu-release-addr = <0x0 0x000000f0>;
                };
        };
+
+       scb {
+               compatible = "simple-bus";
+               #address-cells = <2>;
+               #size-cells = <1>;
+
+               ranges = <0x0 0x7c000000  0x0 0xfc000000  0x03800000>;
+
+               genet: ethernet@7d580000 {
+                       compatible = "brcm,bcm2711-genet-v5";
+                       reg = <0x0 0x7d580000 0x10000>;
+                       #address-cells = <0x1>;
+                       #size-cells = <0x1>;
+                       interrupts = <GIC_SPI 157 IRQ_TYPE_LEVEL_HIGH>,
+                                    <GIC_SPI 158 IRQ_TYPE_LEVEL_HIGH>;
+                       status = "disabled";
+
+                       genet_mdio: mdio@e14 {
+                               compatible = "brcm,genet-mdio-v5";
+                               reg = <0xe14 0x8>;
+                               reg-names = "mdio";
+                               #address-cells = <0x0>;
+                               #size-cells = <0x1>;
+                       };
+               };
+       };
 };
 
 &clk_osc {