mpc85xx: handle MSM460 wifi mac in dts
authorRosen Penev <rosenp@gmail.com>
Sat, 24 Aug 2024 00:39:17 +0000 (17:39 -0700)
committerDavid Bauer <mail@david-bauer.net>
Thu, 10 Oct 2024 02:41:04 +0000 (04:41 +0200)
Userspace handling is deprecated.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac
target/linux/mpc85xx/files/arch/powerpc/boot/dts/msm460.dts

index 0e27dfb8ccdaf40e5974e9d14026703ce2b572f6..20ad8eb44f4735ed72f4db6aee9ae2d289a1d0d5 100644 (file)
@@ -20,11 +20,6 @@ enterasys,ws-ap3710i|\
 extreme-networks,ws-ap3825i)
        mtd_get_mac_ascii cfg2 RADIOADDR${PHYNBR} > /sys${DEVPATH}/macaddress
        ;;
-hpe,msm460)
-       wifi_mac=$(mtd_get_mac_binary colubris-bid 0x1f9bd)
-       [ "$PHYNBR" -eq 0 ] && echo "$wifi_mac" > /sys${DEVPATH}/macaddress
-       [ "$PHYNBR" -eq 1 ] && echo "$(macaddr_add $wifi_mac 16)" > /sys${DEVPATH}/macaddress
-       ;;
 ocedo,panda)
        mtd_get_mac_ascii uboot-env0 wmac$(($PHYNBR + 1)) > /sys${DEVPATH}/macaddress
        ;;
index 46f8e514c98cb1e4be6ae3753174332077894241..3666350271b7f4fd3b591c3ae1030bd76dd57a92 100644 (file)
                                  0x1000000 0x0 0x0
                                  0x1000000 0x0 0x0
                                  0x0 0x100000>;
+
+                       wifi@0,0 {
+                               reg = <0x0000 0 0 0 0>;
+                               nvmem-cells = <&macaddr_hwinfo_1f9bd 0>;
+                               nvmem-cell-names = "mac-address";
+                       };
                };
        };
 
                                  0x1000000 0x0 0x0
                                  0x1000000 0x0 0x0
                                  0x0 0x100000>;
+
+                       wifi@0,0 {
+                               reg = <0x0000 0 0 0 0>;
+                               nvmem-cells = <&macaddr_hwinfo_1f9bd 16>;
+                               nvmem-cell-names = "mac-address";
+                       };
                };
        };