ath79: add QCA956x GMAC config
[openwrt/staging/wigyori.git] / target / linux / ath79 / dts / qca956x.dtsi
index 1b8733a5851d8c9ec83e78b4fad8fb175ae0a195..81453717477f5985dff912c50c720a0d46b40957 100644 (file)
                                #reset-cells = <1>;
                                interrupt-parent = <&cpuintc>;
 
-                               intc3: interrupt-controller@3 {
+                               intc3: interrupt-controller {
                                        compatible = "qca,ar9340-intc";
 
                                        interrupt-parent = <&cpuintc>;
                        #address-cells = <1>;
                        #size-cells = <0>;
                };
+
+               gmac: gmac@18070000 {
+                       compatible = "qca,qca9560-gmac";
+                       reg = <0x18070000 0x64>;
+               };
        };
 
        usb_phy0: usb-phy {
 };
 
 &eth0 {
-       compatible = "qca,qca9560-eth", "syscon";
+       compatible = "qca,qca9560-eth", "syscon", "simple-mfd";
 
        pll-data = <0x03000000 0x00000101 0x00001919>;
        pll-reg = <0 0x48 0>;
        pll-handle = <&pll>;
 
-       phy-mode = "sgmii";
-
        resets = <&rst 9>;
        reset-names = "mac";
 };
 
 &mdio1 {
+       status = "okay";
        resets = <&rst 23>;
        reset-names = "mdio";
        builtin-switch;
+
+       builtin_switch: switch0@1f {
+               compatible = "qca,ar8229-builtin";
+               reg = <0x1f>;
+               resets = <&rst 8>;
+               reset-names = "switch";
+               phy-mode = "gmii";
+               phy4-mii-enable;
+
+               mdio-bus {
+                       #address-cells = <1>;
+                       #size-cells = <0>;
+
+                       swphy0: ethernet-phy@0 {
+                               reg = <0>;
+                               phy-mode = "mii";
+                       };
+
+                       swphy4: ethernet-phy@4 {
+                               reg = <4>;
+                               phy-mode = "mii";
+                       };
+               };
+       };
 };
 
 &eth1 {
-       compatible = "qca,qca9560-eth", "syscon";
+       compatible = "qca,qca9560-eth", "syscon", "simple-mfd";
 
        phy-mode = "gmii";
 
        reset-names = "mac";
 
        status = "disabled";
+
+       fixed-link {
+               speed = <1000>;
+               full-duplex;
+       };
 };