ramips: convert MT7603 EEPROM to NVMEM format
authorShiji Yang <yangshiji66@qq.com>
Mon, 2 Oct 2023 02:12:02 +0000 (10:12 +0800)
committerChristian Marangi <ansuelsmth@gmail.com>
Mon, 9 Oct 2023 09:15:52 +0000 (11:15 +0200)
This patch converts MT7603 WiFi calibration data to NVMEM format. The
EEPROM size is 0x400.

Signed-off-by: Shiji Yang <yangshiji66@qq.com>
60 files changed:
target/linux/ramips/dts/mt7621_afoundry_ew1200.dts
target/linux/ramips/dts/mt7621_asus_rp-ac56.dts
target/linux/ramips/dts/mt7621_asus_rt-ac57u-v1.dts
target/linux/ramips/dts/mt7621_asus_rt-n56u-b1.dts
target/linux/ramips/dts/mt7621_beeline_smartbox-giga.dts
target/linux/ramips/dts/mt7621_beeline_smartbox-turbo-plus.dts
target/linux/ramips/dts/mt7621_bolt_arion.dts
target/linux/ramips/dts/mt7621_buffalo_wsr-1166dhp.dts
target/linux/ramips/dts/mt7621_buffalo_wsr-600dhp.dts
target/linux/ramips/dts/mt7621_comfast_cf-ew72-v2.dts
target/linux/ramips/dts/mt7621_cudy_wr1300-v1.dts
target/linux/ramips/dts/mt7621_cudy_wr1300-v2.dts
target/linux/ramips/dts/mt7621_cudy_wr2100.dts
target/linux/ramips/dts/mt7621_d-team_newifi-d2.dts
target/linux/ramips/dts/mt7621_d-team_pbr-m1.dts
target/linux/ramips/dts/mt7621_etisalat_s3.dts
target/linux/ramips/dts/mt7621_gehua_ghl-r-001.dts
target/linux/ramips/dts/mt7621_hiwifi_hc5962.dts
target/linux/ramips/dts/mt7621_huasifei_ws1208v2.dts
target/linux/ramips/dts/mt7621_iodata_wn-ax1167gr.dts
target/linux/ramips/dts/mt7621_iodata_wn-dx1200gr.dts
target/linux/ramips/dts/mt7621_iodata_wn-gx300gr.dts
target/linux/ramips/dts/mt7621_keenetic_kn-3010.dts
target/linux/ramips/dts/mt7621_lenovo_newifi-d1.dts
target/linux/ramips/dts/mt7621_linksys_e5600.dts
target/linux/ramips/dts/mt7621_linksys_re7000.dts
target/linux/ramips/dts/mt7621_netgear_wac104.dts
target/linux/ramips/dts/mt7621_renkforce_ws-wn530hp3-a.dts
target/linux/ramips/dts/mt7621_samknows_whitebox-v8.dts
target/linux/ramips/dts/mt7621_sercomm_dxx_nand_256m.dtsi
target/linux/ramips/dts/mt7621_sercomm_na502.dts
target/linux/ramips/dts/mt7621_sercomm_na502s.dts
target/linux/ramips/dts/mt7621_snr_snr-cpe-me1.dts
target/linux/ramips/dts/mt7621_snr_snr-cpe-me2-lite.dts
target/linux/ramips/dts/mt7621_telco-electronics_x1.dts
target/linux/ramips/dts/mt7621_tozed_zlt-s12-pro.dts
target/linux/ramips/dts/mt7621_tplink_archer-c6u-v1.dts
target/linux/ramips/dts/mt7621_tplink_archer-x6-v3.dtsi
target/linux/ramips/dts/mt7621_tplink_deco-m4r-v4.dts
target/linux/ramips/dts/mt7621_tplink_eap235-wall-v1.dts
target/linux/ramips/dts/mt7621_tplink_mr600-v2-eu.dts
target/linux/ramips/dts/mt7621_tplink_re350-v1.dts
target/linux/ramips/dts/mt7621_tplink_tl-wpa8631p-v3.dts
target/linux/ramips/dts/mt7621_ubnt_unifi-6-lite.dts
target/linux/ramips/dts/mt7621_unielec_u7621-01-16m.dts
target/linux/ramips/dts/mt7621_unielec_u7621-01.dtsi
target/linux/ramips/dts/mt7621_wavlink_ws-wn572hp3-4g.dts
target/linux/ramips/dts/mt7621_wevo_w2914ns-v2.dtsi
target/linux/ramips/dts/mt7621_winstars_ws-wn583a6.dts
target/linux/ramips/dts/mt7621_xzwifi_creativebox-v1.dts
target/linux/ramips/dts/mt7621_youhua_wr1200js.dts
target/linux/ramips/dts/mt7621_youku_yk-l2.dts
target/linux/ramips/dts/mt7621_zbtlink_zbt-we1326.dts
target/linux/ramips/dts/mt7621_zbtlink_zbt-we3526.dts
target/linux/ramips/dts/mt7621_zbtlink_zbt-wg1602-v04.dtsi
target/linux/ramips/dts/mt7621_zbtlink_zbt-wg1602.dtsi
target/linux/ramips/dts/mt7621_zbtlink_zbt-wg1608.dtsi
target/linux/ramips/dts/mt7621_zbtlink_zbt-wg3526.dtsi
target/linux/ramips/dts/mt7621_zyxel_nr7101.dts
target/linux/ramips/dts/mt7621_zyxel_wap6805.dts

index 8d33f542dc1af0b294c8d7b8566d532283430bd9..0161fcfb41037b699a6f5017547b0619585720c3 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
 
                led {
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index 50047999be7a84c19acd91e2c890ce14ef8fa304..c8e6bc9f28a8852e86997dc58a2adc2f331068d8 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x40000 0x10000>;
-                               read-only;
-
-                               compatible = "nvmem-cells";
                                #address-cells = <1>;
                                #size-cells = <1>;
+                               read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
 
                                macaddr_factory_4: macaddr@4 {
                                        reg = <0x4 0x6>;
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
index bb1c86c2d5df8330938dc8508fcecf360bd9b711..347f6edb95f60a81bdf576368946a76016fec3eb 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
 
                led {
                        led-active-low;
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index c8d286e7ed154ba0deabcbdd6c5e87e44776992f..bce6bd435aa9695af35a265f9ac0fee836619d81 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>;
+                               };
+
+                               macaddr_factory_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
+
+                               macaddr_factory_8004: macaddr@8004 {
+                                       reg = <0x8004 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-
-       macaddr_factory_8004: macaddr@8004 {
-               reg = <0x8004 0x6>;
-       };
-};
index 22fc065eb299076e86533f371faf1a8c9f98fc22..1b61d77c036ad7867eb02c924aa7eb390a4e6f39 100644 (file)
                };
 
                factory: partition@200000 {
+                       compatible = "nvmem-cells";
                        label = "Factory";
                        reg = <0x200000 0x100000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        sercomm,scpart-id = <2>;
                        read-only;
 
-                       compatible = "nvmem-cells";
-                       #address-cells = <1>;
-                       #size-cells = <1>;
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
 
                        macaddr_factory_21000: macaddr@21000 {
                                reg = <0x21000 0x6>;
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
                ieee80211-freq-limit = <2400000 2500000>;
 
-               nvmem-cells = <&macaddr_factory_21000>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_factory_0>, <&macaddr_factory_21000>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <(4)>;
        };
 };
index 507920bac22c0ebe9511d5a0249d3709bca3bf71..9dbc7be0e92f97cd9802e4b6a58b75f747f3ac3a 100644 (file)
                };
 
                factory: partition@200000 {
+                       compatible = "nvmem-cells";
                        label = "Factory";
                        reg = <0x200000 0x100000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        sercomm,scpart-id = <2>;
                        read-only;
 
-                       compatible = "nvmem-cells";
-                       #address-cells = <1>;
-                       #size-cells = <1>;
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
 
                        macaddr_factory_21000: macaddr@21000 {
                                reg = <0x21000 0x6>;
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
                ieee80211-freq-limit = <2400000 2500000>;
 
-               nvmem-cells = <&macaddr_factory_21000>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_factory_0>, <&macaddr_factory_21000>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <(4)>;
        };
 };
index feff4a66e4846700ff065360e08a8669c6a18435..bf29d079bcd0f1847673ac55be421090033343f4 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>;
+                               };
+
+                               macaddr_factory_28: macaddr@28 {
+                                       reg = <0x28 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_28: macaddr@28 {
-               reg = <0x28 0x6>;
-       };
-};
index a8d76b544e2576e2b67330e89866d1fa4595330c..85aca456cb6a7655db4fa230be0980250c9b52fd 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 {
 &pcie1 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
index f46bc256d0c064b62c7ed45f6453ab884232e7d9..932c36c629163840386f2280fce6d418f6a2f1b1 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>;
+                               };
+
+                               macaddr_factory_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie1 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
 &xhci {
        status = "disabled";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-};
index 8b7b4a035ea2d301625b9680cbd39bac13603698..b3a823b1f0850d511014173379bf15e3d52924d4 100644 (file)
                                compatible = "nvmem-cells";
                                reg = <0x40000 0x10000>;
                                read-only;
+
                                nvmem-layout {
                                        compatible = "fixed-layout";
                                        #address-cells = <1>;
                                        #size-cells = <1>;
+
+                                       eeprom_factory_0: eeprom@0 {
+                                               reg = <0x0 0x400>;
+                                       };
+
                                        macaddr_factory_e000: macaddr@e000 {
                                                compatible = "mac-base";
                                                reg = <0xe000 0x6>;
        wifi_2_4_ghz: wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                // Wi-Fi device reads it's MAC address from EEPROM (&factory + 4)
                // adding anything related to mac-address here will cause use random MAC
        };
index cc1afdc95bd6a5899d3cb5e09c3624fe93819c77..108dbc17a5f3e4577ac0ba72170d536f49cedbf4 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 = "pci14c3,7603";
                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";
                ieee80211-freq-limit = <2400000 2500000>;
 
                led {
                function = "gpio";
        };
 };
-
-&bdinfo {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_bdinfo_de00: macaddr@de00 {
-               reg = <0xde00 0x6>;
-       };
-};
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>;
-       };
-};
index b2e75762a5d132910390be2ecb6e24ab934bcee8..28151cdaeeb2f0850f2e55ecc336208a5b5500bb 100644 (file)
@@ -90,7 +90,8 @@
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                        };
 
                        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>;
+                               };
                        };
                };
        };
                };
        };
 };
-
-&bdinfo {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_bdinfo_de00: macaddr@de00 {
-               reg = <0xde00 0x6>;
-       };
-};
index 33deb21dcaa061d07b19c28b391817e79bb57a63..f539c13767144857a431f460e4eec1be7e9ad2b1 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie1 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 03b593e093d11c345049343357ead336e7562baf..bd57bc153bfaac769085b45522347b07139c445c 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie1 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 65d168fd803259a937b09fcc5a6d9445e3234159..411dbdb36625b15d525c506d1ae42e149f272b6b 100644 (file)
                };
 
                factory: partition@200000 {
+                       compatible = "nvmem-cells";
                        label = "Factory";
                        reg = <0x200000 0x100000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        sercomm,scpart-id = <2>;
                        read-only;
 
-                       compatible = "nvmem-cells";
-                       #address-cells = <1>;
-                       #size-cells = <1>;
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
 
                        macaddr_factory_21000: macaddr@21000 {
                                reg = <0x21000 0x6>;
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
                ieee80211-freq-limit = <2400000 2500000>;
 
-               nvmem-cells = <&macaddr_factory_21000>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_factory_0>, <&macaddr_factory_21000>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <(2)>;
        };
 };
index cb9f9bdad1eb0a1bca977b28066230634c166916..824e578f954e9df76288a3c31a2678bb4627dfd2 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie0 {
        wifi@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index d9ca1012ceaf416b8c57274161f3563f266c5ef9..eab4c0faef65f2f9422fc82612a4cd7a62fee55a 100644 (file)
                };
 
                factory: partition@100000 {
+                       compatible = "nvmem-cells";
                        label = "factory";
                        reg = <0x100000 0x40000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        read-only;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
                };
 
                partition@140000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
index fe77f6520746a5158ed5e5f98592e1e9aa272781..f8d25102c51bd20eb3f7e2139b5d378b3a49e6d9 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x40000 0x10000>;
-                               read-only;
-
-                               compatible = "nvmem-cells";
                                #address-cells = <1>;
                                #size-cells = <1>;
+                               read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
 
                                macaddr_factory_e000: macaddr@e000 {
                                        reg = <0xe000 0x6>;
        wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
index 69c79d7dc768db13ba65196eb64a69868409251b..b6bafe8c89abbb0aa477686ac3462e92927266d9 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x40000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_factory_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
                        };
 
                        iNIC_rf: partition@50000 {
+                               compatible = "nvmem-cells";
                                label = "iNIC_rf";
                                reg = <0x50000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_iNIC_rf_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
+
+                               macaddr_iNIC_rf_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
                        };
 
                        partition@60000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&iNIC_rf 0x0>;
+               nvmem-cells = <&eeprom_iNIC_rf_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
 &xhci {
        status = "disabled";
 };
-
-&iNIC_rf {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_iNIC_rf_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-};
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-};
index 653132bc6192f201a81e8e1123501ae54b64acb0..e723bf5a6182272e65a23e1dbbb74de2ca3470c8 100644 (file)
                };
 
                factory: partition@200000 {
+                       compatible = "nvmem-cells";
                        label = "factory";
                        reg = <0x200000 0x200000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
+
+                       macaddr_factory_1e000: macaddr@1e000 {
+                               reg = <0x1e000 0x6>;
+                       };
+
+                       macaddr_factory_1e006: macaddr@1e006 {
+                               reg = <0x1e006 0x6>;
+                       };
                };
 
                partition@400000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-
-               mediatek,mtd-eeprom = <&factory 0x0>;
                ieee80211-freq-limit = <2400000 2500000>;
+
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
 &xhci {
        status = "disabled";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_1e000: macaddr@1e000 {
-               reg = <0x1e000 0x6>;
-       };
-
-       macaddr_factory_1e006: macaddr@1e006 {
-               reg = <0x1e006 0x6>;
-       };
-};
index 8a09675bffbe7a8044d5a42f86c207fc9f39429f..f2cd28ad1c7da4f3425cc6f3fdf69f0d45c33408 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>;
+                               };
+
+                               macaddr_factory_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
 &xhci {
        status = "disabled";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-};
index 69080df6822ae477bee6ebf475619b38881b526f..8382aaba654805f9ab4fe4d7602672c288e43b7c 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "rf-eeprom";
                                reg = <0x40000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
+
+                               macaddr_factory_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
+
+                               macaddr_factory_28: macaddr@28 {
+                                       reg = <0x28 0x6>;
+                               };
                        };
 
                        firmware1: partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                ieee80211-freq-limit = <5000000 6000000>;
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-
-       macaddr_factory_28: macaddr@28 {
-               reg = <0x28 0x6>;
-       };
-};
index 810ca3361af51f83dbd2a613861fe81c787f093a..b5d606f17eedc8e8b37b096e9a33b421f2681456 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie1 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 3b23a25f8b5163da6975d810b9193cfd722634e6..32015b6a2afb0968e5602143f9f6d853f9ad49ad 100644 (file)
                };
 
                factory: partition@c0000 {
+                       compatible = "nvmem-cells";
                        label = "factory";
                        reg = <0xc0000 0x40000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        read-only;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
                };
 
                partition@100000 {
        mt76@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
index 5e33f4891590aee1662ac649ec19209847eb5eb7..d3505e774dcec024787c551bd08095470d872596 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>;
+                               };
+
+                               macaddr_factory_2e: macaddr@2e {
+                                       reg = <0x2e 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                };
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_2e: macaddr@2e {
-               reg = <0x2e 0x6>;
-       };
-};
index 97aa4a90d1b2a747c77ab0204573df83737cd475..5736525282460c4d125762d7b5a416b3747095ec 100644 (file)
                };
 
                factory: partition@2e00000 {
+                       compatible = "nvmem-cells";
                        label = "factory";
                        reg = <0x2e00000 0x100000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        read-only;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
+
+                       macaddr_factory_4: macaddr@4 {
+                               reg = <0x4 0x6>;
+                       };
                };
 
                partition@4200000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
 &xhci {
        status = "disabled";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-};
index c56c2f1554c0231fff516eb4c660fd2744d42d77..7722d3d27829ae22e63f6c9e9c2adbeff04bd448 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>;
+                               };
+
+                               macaddr_factory_4: macaddr@4 {
+                                       reg = <0x4 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi0: wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
-               nvmem-cells = <&macaddr_factory_4>;
-               nvmem-cell-names = "mac-address";
        };
 };
 
 &xhci {
        status = "disabled";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_4: macaddr@4 {
-               reg = <0x4 0x6>;
-       };
-};
index d1f51feddddf6a043d6184913d5ce77ebba85ca2..76c0f19781f83d0d343620d6a52dc3d6ff409c08 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie1 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index a0534bdabd9582ef2118fcd9a3a6e646923e03b8..d51ff8212af7f6e02ce234098ee2c4aeef8a7c8d 100644 (file)
                };
 
                factory: partition@200000 {
+                       compatible = "nvmem-cells";
                        label = "Factory";
                        reg = <0x200000 0x100000>;
                        sercomm,scpart-id = <2>;
-                       read-only;
-
-                       compatible = "nvmem-cells";
                        #address-cells = <1>;
                        #size-cells = <1>;
+                       read-only;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
 
                        macaddr_factory_21000: macaddr@21000 {
                                reg = <0x21000 0x6>;
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
index 9ec4cf77888cf87e5c92308dc9dbc8a897f6b71b..f3e9e2bfd4643eebb6d02303453320e71e9aebc2 100644 (file)
                };
 
                factory: partition@100000 {
+                       compatible = "nvmem-cells";
                        label = "factory";
                        reg = <0x100000 0x40000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
+
+                       macaddr_factory_e000: macaddr@e000 {
+                               reg = <0xe000 0x6>;
+                       };
                };
 
                partition@140000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
-               nvmem-cells = <&macaddr_factory_e000>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_factory_0>, <&macaddr_factory_e000>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <2>;
                ieee80211-freq-limit = <2400000 2500000>;
        };
 &uartlite3 {
        status = "okay";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index dc71dbd050297acbeb293607bd033b576baa3509..705ee0dd9bd69817d80b1d7aa00753a27fb6669a 100644 (file)
                };
 
                factory: partition@100000 {
+                       compatible = "nvmem-cells";
                        label = "factory";
                        reg = <0x100000 0x40000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
+
+                       macaddr_factory_e000: macaddr@e000 {
+                               reg = <0xe000 0x6>;
+                       };
                };
 
                partition@140000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
-               nvmem-cells = <&macaddr_factory_e000>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_factory_0>, <&macaddr_factory_e000>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <2>;
                ieee80211-freq-limit = <2400000 2500000>;
        };
 &uartlite2 {
        status = "okay";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index 7f0dbf772df6313d8a4e766da03b43649c9b5734..625edc16fe049d14bfef106909ffc769790e5f60 100644 (file)
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "Factory";
                                reg = <0x40000 0x10000>;
-                               read-only;
-
-                               compatible = "nvmem-cells";
                                #address-cells = <1>;
                                #size-cells = <1>;
+                               read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
 
                                macaddr_factory_e000: macaddr@e000 {
                                        reg = <0xe000 0x6>;
index 38cd1cd8fd87c0e4a06e2dfe63595ad39eabeee9..a85eb55be2d6d90e3d5a8b3bffb80643de388c54 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                ieee80211-freq-limit = <5000000 6000000>;
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 23e85f990229d8258a28664e98fdb73ec50f705f..2241a977884267cc4d93cabf3ab32cc5c4d12b71 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>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        firmware: partition@50000 {
        wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                };
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 5a94bbda829de0c97c8cba23a66fbcb00c49d117..dca8f3d18a50e3a227af3be8748891010257bd7a 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x40000 0x10000>;
-                               read-only;
-
-                               compatible = "nvmem-cells";
                                #address-cells = <1>;
                                #size-cells = <1>;
+                               read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
 
                                macaddr_factory_e000: macaddr@e000 {
                                        reg = <0xe000 0x6>;
        wifi1: mt76@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
index c626df1ef4e6f4d5fb56683dd14a8da8a819a981..f45cbf28ad05d3f0375f2bc5ab5b6840e03ec649 100644 (file)
                        };
 
                        config: partition@fa0000 {
+                               compatible = "nvmem-cells";
                                label = "config";
                                reg = <0xfa0000 0x010000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_config_8: macaddr@8 {
+                                       reg = <0x8 0x6>;
+                               };
                        };
 
                        partition@fb0000 {
                        };
 
                        radio: partition@ff0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0xff0000 0x010000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
        mt76@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&radio 0x0>;
-               nvmem-cells = <&macaddr_config_8>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_radio_0>, <&macaddr_config_8>;
+               nvmem-cell-names = "eeprom", "mac-address";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
 &xhci {
        vbus-supply = <&reg_usb_vbus>;
 };
-
-&config {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_config_8: macaddr@8 {
-               reg = <0x8 0x6>;
-       };
-};
index 217c1b60fe429f040b1240ac82b34263faa8d1c3..621cb6c2d73fdeaf8fa52f15454b0f8258ae385d 100644 (file)
                        };
 
                        config: partition@fa0000 {
+                               compatible = "nvmem-cells";
                                label = "config";
                                reg = <0xfa0000 0x50000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_config_8: macaddr@8 {
+                                       reg = <0x8 0x6>;
+                               };
                        };
 
                        radio: partition@ff0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0xff0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&radio 0x0>;
-               nvmem-cells = <&macaddr_config_8>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_radio_0>, <&macaddr_config_8>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <1>;
                ieee80211-freq-limit = <2400000 2500000>;
        };
                };
        };
 };
-
-&config {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_config_8: macaddr@8 {
-               reg = <0x8 0x6>;
-       };
-};
index 3d17dbf599cdcb39fba7a7950e1d06ecd99966ad..63631355bfd0d84ee1515a862bedea50cda7cdd9 100644 (file)
                        };
 
                        radio: partition@ff0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0xff0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&radio 0x0>;
+               nvmem-cells = <&eeprom_radio_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
index cd7cae635509ca0adb9d23bd8740ee4792dfddc7..691f805160a94220c79355cf7a0fb9f87a9295ba 100644 (file)
                        };
 
                        info: partition@90000 {
+                               compatible = "nvmem-cells";
                                label = "product-info";
                                reg = <0x90000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_info_8: macaddr@8 {
+                                       reg = <0x8 0x6>;
+                               };
                        };
 
                        partition@a0000 {
                        };
 
                        radio: partition@ff0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0xff0000 0x010000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
 &pcie0 {
        wifi@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&radio 0x0>;
-               nvmem-cells = <&macaddr_info_8>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_radio_0>, <&macaddr_info_8>;
+               nvmem-cell-names = "eeprom", "mac-address";
        };
 };
 
                };
        };
 };
-
-&info {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_info_8: macaddr@8 {
-               reg = <0x8 0x6>;
-       };
-};
index b7475ec15badb1f61836b9e57177b49b6372d019..4ceb107129ad373f586e82754940ebbc7da93a84 100644 (file)
                        };
 
                        romfile: partition@fc0000 {
+                               compatible = "nvmem-cells";
                                label = "romfile";
                                reg = <0xfc0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_romfile_f100: romfile@f100 {
+                                       reg = <0xf100 0x6>;
+                               };
                        };
 
                        partition@fd0000 {
                        };
 
                        radio: partition@fe0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0xfe0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
        mt76@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               nvmem-cells = <&macaddr_romfile_f100>;
-               nvmem-cell-names = "mac-address";
-               mediatek,mtd-eeprom = <&radio 0x0>;
-               mtd-mac-address = <&romfile 0xf100>;
+               nvmem-cells = <&eeprom_radio_0>, <&macaddr_romfile_f100>;
+               nvmem-cell-names = "eeprom", "mac-address";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                };
        };
 };
-
-&romfile {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_romfile_f100: romfile@f100 {
-               reg = <0xf100 0x6>;
-       };
-};
index 866abf87c613a181841f84d445f92fd3fb47d08b..e6653089311d3db64cf4bba460a5e779ef0fb979 100644 (file)
                        };
 
                        config: partition@600000 {
+                               compatible = "nvmem-cells";
                                label = "config";
                                reg = <0x600000 0x50000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_config_10008: macaddr@10008 {
+                                       reg = <0x10008 0x6>;
+                               };
                        };
 
                        radio: partition@7f0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0x7f0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&radio 0x0>;
-               nvmem-cells = <&macaddr_config_10008>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_radio_0>, <&macaddr_config_10008>;
+               nvmem-cell-names = "eeprom", "mac-address";
                mac-address-increment = <1>;
        };
 };
                function = "gpio";
        };
 };
-
-&config {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_config_10008: macaddr@10008 {
-               reg = <0x10008 0x6>;
-       };
-};
index 0d466f1e6610cf6313272fd2af553409df9926e2..c38068f08f1fcff6e6504546060637e3eac62ab5 100644 (file)
                        };
 
                        config: partition@730000 {
+                               compatible = "nvmem-cells";
                                label = "config";
                                reg = <0x730000 0xc0000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_config_2008: macaddr@2008 {
+                                       reg = <0x2008 0x6>;
+                               };
                        };
 
                        radio: partition@7f0000 {
+                               compatible = "nvmem-cells";
                                label = "radio";
                                reg = <0x7f0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_radio_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
                };
        };
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&radio 0x0>;
-               nvmem-cells = <&macaddr_config_2008>;
-               nvmem-cell-names = "mac-address";
+               nvmem-cells = <&eeprom_radio_0>, <&macaddr_config_2008>;
+               nvmem-cell-names = "eeprom", "mac-address";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
                };
        };
 };
-
-&config {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_config_2008: macaddr@2008 {
-               reg = <0x2008 0x6>;
-       };
-};
index 54e372eca396b07d9ce99a683a891060c81180aa..8f78a60557c9090e6ba52ae04ccd1ea3e3c3ee36 100644 (file)
                        };
 
                        factory: partition@70000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x70000 0x40000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
                        };
 
                        eeprom: partition@b0000 {
+                               compatible = "nvmem-cells";
                                label = "eeprom";
                                reg = <0xb0000 0x10000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
                                read-only;
+
+                               macaddr_eeprom_0: macaddr@0 {
+                                       reg = <0x0 0x6>;
+                               };
+
+                               macaddr_eeprom_6: macaddr@6 {
+                                       reg = <0x6 0x6>;
+                               };
                        };
 
                        partition@c0000 {
 };
 
 &wlan_2g {
-       mediatek,mtd-eeprom = <&factory 0x0>;
-
-       nvmem-cells = <&macaddr_eeprom_0>;
-       nvmem-cell-names = "mac-address";
+       nvmem-cells = <&eeprom_factory_0>, <&macaddr_eeprom_0>;
+       nvmem-cell-names = "eeprom", "mac-address";
 };
 
 &wlan_5g {
 
        mediatek,disable-radar-background;
 };
-
-&eeprom {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_eeprom_0: macaddr@0 {
-               reg = <0x0 0x6>;
-       };
-
-       macaddr_eeprom_6: macaddr@6 {
-               reg = <0x6 0x6>;
-       };
-};
index 8780b17b80b8f0ad7399bebd1e965347f95c59f5..b932f901f73dfbe9623dc224abf0e3b260fb79e3 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
        nvmem-cells = <&macaddr_factory_e006>;
        nvmem-cell-names = "mac-address";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index f2900e48060be2bc0c179653430f7a45a3a2b42f..d2bad654c911ad160d7f90942f283687b46e190b 100644 (file)
@@ -54,7 +54,8 @@
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
        };
 };
index 60d0708a80e83f0cf74ec5a504409ec3ce9db831..733814167691d772e4e8c52fd476004435382129 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
 };
 
 &pcie0 {
-       wifi0: mt76@0,0 {
+       mt76@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               ieee80211-freq-limit = <2400000 2500000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
        };
 };
 
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
-
-&wifi0{
-       ieee80211-freq-limit = <2400000 2500000>;
-};
-
 &wifi1{
        ieee80211-freq-limit = <5000000 6000000>;
 };
index cfd2344d21c6877df5d33f1ccc595132447a0862..01dd9afddb07a9512ef5d4befd5bfaa486df4155 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>;
+                               };
+
+                               macaddr_factory_2e: macaddr@2e {
+                                       reg = <0x2e 0x6>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
 
                led {
                        led-sources = <0>;
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_2e: macaddr@2e {
-               reg = <0x2e 0x6>;
-       };
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index ec81839d1d24908a45f265ab148790929acbdb63..fde07a638632b0b367de4bd01e17210fc342a1d7 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
 &xhci {
        status = "disabled";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 32f7e5056a313c6e8352e90af6935e85e821c1aa..ac69a42f0128eff0d0bb00303755e7f2e9484997 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "pci1400,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index 2d61b8756052bff9f127cca352f95e78aedc17b4..638923e7ce2b3ee28ffb0b766fb613ac0f25dd02 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 5342b40507af3f40516724741752ee360edabf5b..eda5ce964af5808bb86837fb10c668d814e75f30 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
                led {
                        led-active-low;
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 99b9652b7ab31c5058b7ca57c11fe9b94ee6c494..1244acb0dab501e616228bf695483a034d916bdc 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        partition@50000 {
        wifi1: wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
                ieee80211-freq-limit = <2400000 2500000>;
 
                led {
 &sdhci {
        status = "okay";
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index a6d0e9a7c2053d21d73b8a496b088fa6c14f0c9b..decf80fa5ef2c118e2c6da17b6030cd990c85bfa 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        firmware: partition@50000 {
        wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 64492af4d8a276c3314c3f48af86e30363a51c14..4dcdce72056c8aacca70734c1b93ac0daec03675 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        firmware: partition@50000 {
        wifi0: wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index c80544cfc95ddfea4c4b7b61a6d9a816abd889bf..45bd4a753f29ada8b1397785b170153cff40eb4d 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
+
+                               macaddr_factory_e006: macaddr@e006 {
+                                       reg = <0xe006 0x6>;
+                               };
                        };
 
                        firmware: partition@50000 {
        wifi0: wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-
-       macaddr_factory_e006: macaddr@e006 {
-               reg = <0xe006 0x6>;
-       };
-};
index 303708fab0e842b51231a122fac9344891011518..8b5a0e7adca1da3a5545e622d85e58c6936378b0 100644 (file)
                        };
 
                        factory: partition@40000 {
+                               compatible = "nvmem-cells";
                                label = "factory";
                                reg = <0x40000 0x10000>;
-                               read-only;
-
-                               compatible = "nvmem-cells";
                                #address-cells = <1>;
                                #size-cells = <1>;
+                               read-only;
+
+                               eeprom_factory_0: eeprom@0 {
+                                       reg = <0x0 0x400>;
+                               };
 
                                macaddr_factory_e000: macaddr@e000 {
                                        reg = <0xe000 0x6>;
        wifi@0,0 {
                compatible = "mediatek,mt76";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
index 9af057378d184b1b061912a224ea69528b3a6654..6391a51e52929eb2d712c0cc5f7992b03e33e7ab 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>;
+                               };
+
+                               macaddr_factory_e000: macaddr@e000 {
+                                       reg = <0xe000 0x6>;
+                               };
                        };
 
                        firmware: partition@50000 {
        wifi0: wifi@0,0 {
                compatible = "pci14c3,7603";
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0000>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index 63d992973aa027c11a43d2953f716dbc11196443..ace7a08bd89dd6e57e418004a7e16b6b2f45a2b2 100644 (file)
                };
 
                factory: partition@100000 {
+                       compatible = "nvmem-cells";
                        label = "Factory";
                        reg = <0x100000 0x40000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        read-only;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
+
+                       macaddr_factory_e000: macaddr@e000 {
+                               reg = <0xe000 0x6>;
+                       };
                };
 
                partition@140000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};
index a46723664099267257b08f3b1925f5a48552d253..5df2f3c6ab69f918045514fe658c27bdb81fc6ea 100644 (file)
                };
 
                factory: partition@200000 {
+                       compatible = "nvmem-cells";
                        label = "Factory";
                        reg = <0x200000 0x100000>;
+                       #address-cells = <1>;
+                       #size-cells = <1>;
                        read-only;
+
+                       eeprom_factory_0: eeprom@0 {
+                               reg = <0x0 0x400>;
+                       };
+
+                       macaddr_factory_e000: macaddr@e000 {
+                               reg = <0xe000 0x6>;
+                       };
                };
 
                partition@300000 {
 &pcie0 {
        mt76@0,0 {
                reg = <0x0000 0 0 0 0>;
-               mediatek,mtd-eeprom = <&factory 0x0>;
+               nvmem-cells = <&eeprom_factory_0>;
+               nvmem-cell-names = "eeprom";
        };
 };
 
                function = "gpio";
        };
 };
-
-&factory {
-       compatible = "nvmem-cells";
-       #address-cells = <1>;
-       #size-cells = <1>;
-
-       macaddr_factory_e000: macaddr@e000 {
-               reg = <0xe000 0x6>;
-       };
-};