ramips: convert MT7603 EEPROM to NVMEM format
[openwrt/staging/dangole.git] / target / linux / ramips / dts / mt7621_cudy_wr1300-v2.dts
index a5d2fc4607934388d985e38907f8dfdd2e63e29b..0aafde6c085fbabb28abbeb97a99557431ca5995 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x40000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
 
                        partition@50000 {
                        };
 
                        bdinfo: partition@ff0000 {
+                               compatible = "nvmem-cells";
                                label = "bdinfo";
                                reg = <0xff0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_bdinfo_de00: macaddr@de00 {
+                                       reg = <0xde00 0x6>;
+                               };
                        };
                };
        };
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
-               nvmem-cells = <&macaddr_bdinfo_de00>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_factory_0>, <&macaddr_bdinfo_de00>;
+               nvmem-cell-names = "eeprom", "mac-address";
        };
 };
 
                function = "gpio";
        };
 };
-
-&bdinfo {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_bdinfo_de00: macaddr@de00 {
-               reg = <0xde00 0x6>;
-       };
-};