ramips: convert to new LED color/function format where possible
[openwrt/staging/jow.git] / target / linux / ramips / dts / mt7621_netgear_sercomm_ayx.dtsi
index ae9e40e621160f4c914cd67ffa466d52ddb9a497..6e225c0825c0b10998996e8fa23f622a52167f7d 100644 (file)
@@ -4,6 +4,7 @@
 
 #include <dt-bindings/gpio/gpio.h>
 #include <dt-bindings/input/input.h>
+#include <dt-bindings/leds/common.h>
 
 / {
        compatible = "mediatek,mt7621-soc";
                compatible = "gpio-leds";
 
                led_power: power {
-                       label = "green:power";
+                       function = LED_FUNCTION_POWER;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
                };
 
                usb {
-                       label = "green:usb";
+                       function = LED_FUNCTION_USB;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
                        trigger-sources = <&xhci_ehci_port1>, <&ehci_port2>;
                        linux,default-trigger = "usbport";
                };
 
                internet {
-                       label = "green:wan";
+                       function = LED_FUNCTION_WAN;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 13 GPIO_ACTIVE_LOW>;
                };
 
@@ -64,7 +68,8 @@
                };
 
                wps {
-                       label = "green:wps";
+                       function = LED_FUNCTION_WPS;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
                };
        };
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x8000>;
                ieee80211-freq-limit = <5000000 6000000>;
+               nvmem-cells = <&eeprom1>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
-&pcie1 {
+&pcie2 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
                ieee80211-freq-limit = <2400000 2500000>;
+               nvmem-cells = <&eeprom0>;
+               nvmem-cell-names = "eeprom";
+       };
+};
+
+&gmac1 {
+       status = "okay";
+       label = "wan";
+       phy-handle = <&ethphy4>;
+};
+
+&mdio {
+       ethphy4: ethernet-phy@4 {
+               reg = <4>;
        };
 };
 
                        status = "okay";
                        label = "lan1";
                };
-
-               wan: port@4 {
-                       status = "okay";
-                       label = "wan";
-               };
        };
 };