bmips: convert mtd-mac-address to nvmem implementation
authorAnsuel Smith <ansuelsmth@gmail.com>
Sun, 18 Jul 2021 17:37:39 +0000 (19:37 +0200)
committerPetr Štetiar <ynezz@true.cz>
Mon, 19 Jul 2021 12:51:22 +0000 (14:51 +0200)
Define nvmem-cells and convert mtd-mac-address to nvmem implementation.
The conversion is done with an automated script.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
target/linux/bmips/dts/bcm63168-comtrend-vr-3032u.dts
target/linux/bmips/dts/bcm6318-comtrend-ar-5315u.dts
target/linux/bmips/dts/bcm6328-comtrend-ar-5387un.dts
target/linux/bmips/dts/bcm6358-huawei-hg556a-b.dts
target/linux/bmips/dts/bcm6362-netgear-dgnd3700-v2.dts
target/linux/bmips/dts/bcm6368-comtrend-vr-3025u.dts

index 094dca158571f0f1d0f7842dd83352899ec89cca..95fda0843c48de3ae697e9d169ee5af16cd801b7 100644 (file)
@@ -44,7 +44,8 @@
 &ethernet {
        status = "okay";
 
-       mtd-mac-address = <&cferom 0x6a0>;
+       nvmem-cells = <&macaddr_cferom_6a0>;
+       nvmem-cell-names = "mac-address";
 };
 
 &leds {
 &usbh {
        status = "okay";
 };
+
+&cferom {
+       compatible = "nvmem-cells";
+       #address-cells = <1>;
+       #size-cells = <1>;
+
+       macaddr_cferom_6a0: macaddr@6a0 {
+               reg = <0x6a0 0x6>;
+       };
+};
index 0a53ece1409b537fe7b1023e40e3657dd7c66963..a54d63277054dab7ff8927aa0995f1bfdadb9264 100644 (file)
@@ -42,8 +42,9 @@
                pci-bus = <1>;
                pci-dev = <0>;
 
-               mtd-mac-address = <&cfe 0x6a0>;
-               mtd-mac-address-increment = <1>;
+               nvmem-cells = <&macaddr_cfe_6a0>;
+               nvmem-cell-names = "mac-address";
+               mac-address-increment = <1>;
 
                brcm,sprom-fixups = <6 0x1c00>,
                                    <65 0x1255>,
@@ -66,7 +67,8 @@
 &ethernet {
        status = "okay";
 
-       mtd-mac-address = <&cfe 0x6a0>;
+       nvmem-cells = <&macaddr_cfe_6a0>;
+       nvmem-cell-names = "mac-address";
 };
 
 &hsspi {
 &usbh {
        status = "okay";
 };
+
+&cfe {
+       compatible = "nvmem-cells";
+       #address-cells = <1>;
+       #size-cells = <1>;
+
+       macaddr_cfe_6a0: macaddr@6a0 {
+               reg = <0x6a0 0x6>;
+       };
+};
index 06fe1f90095b1f14c8f5ae343011a7b91cabdffe..47db0809e19ebbd02871f17d2d5dc3b37eb7d83d 100644 (file)
@@ -34,8 +34,9 @@
                pci-bus = <1>;
                pci-dev = <0>;
 
-               mtd-mac-address = <&cfe 0x6a0>;
-               mtd-mac-address-increment = <1>;
+               nvmem-cells = <&macaddr_cfe_6a0>;
+               nvmem-cell-names = "mac-address";
+               mac-address-increment = <1>;
 
                brcm,sprom-fixups = <2 0x05bb>,
                                    <65 0x1204>,
@@ -71,7 +72,8 @@
 &ethernet {
        status = "okay";
 
-       mtd-mac-address = <&cfe 0x6a0>;
+       nvmem-cells = <&macaddr_cfe_6a0>;
+       nvmem-cell-names = "mac-address";
 };
 
 &hsspi {
 &usbh {
        status = "okay";
 };
+
+&cfe {
+       compatible = "nvmem-cells";
+       #address-cells = <1>;
+       #size-cells = <1>;
+
+       macaddr_cfe_6a0: macaddr@6a0 {
+               reg = <0x6a0 0x6>;
+       };
+};
index 1ec5a7151529ff32f792c9cc39fab4b271c27155..6c8b093edfa95a9536797e5bd0da8581ae500c05 100644 (file)
 
                pci-dev = <1>;
 
-               mtd-mac-address = <&cfe 0x6a0>;
-               mtd-mac-address-increment = <1>;
+               nvmem-cells = <&macaddr_cfe_6a0>;
+               nvmem-cell-names = "mac-address";
+               mac-address-increment = <1>;
 
                ath,eeprom = <&cal_data 0x1e000>;
                ath,endian-check;
 &usbh {
        status = "okay";
 };
+
+&cfe {
+       compatible = "nvmem-cells";
+       #address-cells = <1>;
+       #size-cells = <1>;
+
+       macaddr_cfe_6a0: macaddr@6a0 {
+               reg = <0x6a0 0x6>;
+       };
+};
index 9e5b1610dc06a6a24065ab613096173707e62bad..b99fecaaa626e3cf8890ec255df49f08ac6702af 100644 (file)
@@ -67,7 +67,8 @@
 &ethernet {
        status = "okay";
 
-       mtd-mac-address = <&cferom 0x6a0>;
+       nvmem-cells = <&macaddr_cferom_6a0>;
+       nvmem-cell-names = "mac-address";
 };
 
 &leds {
 &usbh {
        status = "okay";
 };
+
+&cferom {
+       compatible = "nvmem-cells";
+       #address-cells = <1>;
+       #size-cells = <1>;
+
+       macaddr_cferom_6a0: macaddr@6a0 {
+               reg = <0x6a0 0x6>;
+       };
+};
index b4d2047cd818ef9f298be8e0b1d9c19c2a6cfa96..29d8dfd56e0960f16bca21952ab2c63eda3ad9da 100644 (file)
@@ -63,8 +63,9 @@
                pci-bus = <0>;
                pci-dev = <1>;
 
-               mtd-mac-address = <&cfe 0x6a0>;
-               mtd-mac-address-increment = <1>;
+               nvmem-cells = <&macaddr_cfe_6a0>;
+               nvmem-cell-names = "mac-address";
+               mac-address-increment = <1>;
 
                brcm,sprom-fixups = <97 0xfeb3>,
                                    <98 0x1618>,
@@ -82,7 +83,8 @@
 &ethernet {
        status = "okay";
 
-       mtd-mac-address = <&cfe 0x6a0>;
+       nvmem-cells = <&macaddr_cfe_6a0>;
+       nvmem-cell-names = "mac-address";
 };
 
 &ohci {
 &usbh {
        status = "okay";
 };
+
+&cfe {
+       compatible = "nvmem-cells";
+       #address-cells = <1>;
+       #size-cells = <1>;
+
+       macaddr_cfe_6a0: macaddr@6a0 {
+               reg = <0x6a0 0x6>;
+       };
+};