ramips: add support for TP-Link RE205 v3
[openwrt/openwrt.git] / target / linux / ramips / dts / mt7620n_zbtlink_zbt-wr8305rt.dts
index 675b42671b0fa393250045224c9a84c62d6d5bcf..137b6f6e0a2cccc497ca2f59ab40aad4ed17939a 100644 (file)
@@ -1,9 +1,8 @@
-/dts-v1/;
-
 #include "mt7620n.dtsi"
 
 #include <dt-bindings/gpio/gpio.h>
 #include <dt-bindings/input/input.h>
+#include <dt-bindings/leds/common.h>
 
 / {
        compatible = "zbtlink,zbt-wr8305rt", "ralink,mt7620n-soc";
                compatible = "gpio-leds";
 
                led_sys: sys {
-                       label = "zbt-wr8305rt:green:sys";
+                       label = "green:sys";
                        gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
                };
 
                lan {
-                       label = "zbt-wr8305rt:green:usb";
+                       function = LED_FUNCTION_USB;
+                       color = <LED_COLOR_ID_GREEN>;
                        gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
                        trigger-sources = <&ohci_port1>, <&ehci_port1>;
                        linux,default-trigger = "usbport";
                };
 
                wifi {
-                       label = "zbt-wr8305rt:green:wifi";
+                       label = "green:wifi";
                        gpios = <&gpio3 0 GPIO_ACTIVE_LOW>;
                };
        };
                                read-only;
                        };
 
-                       factory: partition@40000 {
+                       partition@40000 {
                                label = "factory";
                                reg = <0x40000 0x10000>;
                                read-only;
+
+                               nvmem-layout {
+                                       compatible = "fixed-layout";
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       eeprom_factory_0: eeprom@0 {
+                                               reg = <0x0 0x200>;
+                                       };
+
+                                       macaddr_factory_4: macaddr@4 {
+                                               reg = <0x4 0x6>;
+                                       };
+                               };
                        };
 
                        partition@50000 {
        pinctrl-names = "default";
        pinctrl-0 = <&ephy_pins>;
 
-       mtd-mac-address = <&factory 0x4>;
+       nvmem-cells = <&macaddr_factory_4>;
+       nvmem-cell-names = "mac-address";
 
        mediatek,portmap = "llllw";
 };
 
 &wmac {
-       ralink,mtd-eeprom = <&factory 0x0>;
+       nvmem-cells = <&eeprom_factory_0>;
+       nvmem-cell-names = "eeprom";
 };
 
 &state_default {