ramips: mt7620a: use mac-base
[openwrt/staging/hauke.git] / target / linux / ramips / dts / mt7620a_dlink_dir-510l.dts
index 6ad3f415601c3b3d639466d44a70229278d77cd5..febfd2e32eda9639c9ad193949d941c7061e637f 100644 (file)
@@ -4,6 +4,7 @@
 
 #include <dt-bindings/input/input.h>
 #include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/mtd/partitions/uimage.h>
 
 / {
        compatible = "dlink,dir-510l", "ralink,mt7620a-soc";
        status = "okay";
 };
 
-&gpio0 {
-       status = "okay";
-};
-
 &spi0 {
        status = "okay";
 
@@ -89,7 +86,9 @@
                        };
 
                        partition@210000 {
-                               compatible = "amit,jimage";
+                               compatible = "openwrt,uimage", "denx,uimage";
+                               openwrt,ih-magic = <IH_MAGIC_OKLI>;
+                               openwrt,offset = <0x10000>;
                                label = "firmware";
                                reg = <0x210000 0xde0000>;
                        };
                                label = "config";
                                reg = <0xff0000 0x10000>;
                                read-only;
+
+                               nvmem-layout {
+                                       compatible = "fixed-layout";
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       eeprom_config_e05d: eeprom@e05d {
+                                               reg = <0xe05d 0x200>;
+                                       };
+
+                                       macaddr_config_e490: macaddr@e490 {
+                                               compatible = "mac-base";
+                                               reg = <0xe490 0x6>;
+                                               #nvmem-cell-cells = <1>;
+                                       };
+                               };
                        };
                };
        };
 &pcie0 {
        mt76x0e@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mtd-mac-address = <&config 0xe490>;
-               mtd-mac-address-increment = <(2)>;
-               mediatek,mtd-eeprom = <&config 0xe05d>;
+               nvmem-cells = <&eeprom_config_e05d>, <&macaddr_config_e490 2>;
+               nvmem-cell-names = "eeprom", "mac-address";
        };
 };
 
-&gsw {
-       mediatek,port4 = "ephy";
-};
-
 &state_default {
        default {
                groups = "i2c", "uartf";