ramips: convert mt76 PCIe NIC EEPROM to NVMEM format for legacy SoCs
[openwrt/staging/xback.git] / target / linux / ramips / dts / mt7620a_lava_lr-25g001.dts
index 07355a05a5ad3f7acd472f2ad1676bee9eecd65c..f7a5aed064c445dad006d5160fb253975faf490b 100644 (file)
                        };
 
                        config: partition@ff0000 {
+                               compatible = "nvmem-cells";
                                label = "config";
                                reg = <0xff0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_config_e08a: eeprom@e08a {
+                                       reg = <0xe08a 0x200>;
+                               };
+
+                               macaddr_config_e07e: macaddr@e07e {
+                                       reg = <0xe07e 0x6>;
+                               };
                        };
                };
        };
 &pcie0 {
        mt76x0e@0,0 {
                reg = <0x0000 0 0 0 0>;
-               nvmem-cells = <&macaddr_config_e07e>;
-               nvmem-cell-names = "mac-address";
-               mac-address-increment = <(2)>;
-               mediatek,mtd-eeprom = <&config 0xe08a>;
+               nvmem-cells = <&eeprom_config_e08a>, <&macaddr_config_e07e>;
+               nvmem-cell-names = "eeprom", "mac-address";
+               mac-address-increment = <2>;
        };
 };
 
                function = "gpio";
        };
 };
-
-&config {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_config_e07e: macaddr@e07e {
-               reg = <0xe07e 0x6>;
-       };
-};