]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
mediatek: Fix setting MAC address for some devices 20100/head
authorHauke Mehrtens <hauke@hauke-m.de>
Fri, 19 Sep 2025 22:09:29 +0000 (00:09 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Sat, 20 Sep 2025 17:26:16 +0000 (19:26 +0200)
This fixes a previous commit breaking setting the MAC address for the
wifi devices.

Fixes: 9ed4d27fbf90 ("mediatek: filogic: fix 5G MAC address for Zyxel EX5601")
Link: https://github.com/openwrt/openwrt/pull/20100
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
target/linux/mediatek/filogic/base-files/etc/hotplug.d/ieee80211/11_fix_wifi_mac

index 819fa44b93e1ec9472abce21d04ef82e0b3a0b82..d753941c62ab9cc4024e352d8891e2b1bc2712c0 100644 (file)
@@ -215,7 +215,10 @@ case "$board" in
        routerich,ax3000-ubootmod|\
        zbtlink,zbt-z8102ax|\
        zbtlink,zbt-z8102ax-v2|\
-       zbtlink,zbt-z8103ax|\
+       zbtlink,zbt-z8103ax)
+               addr=$(mtd_get_mac_binary "Factory" 0x4)
+               [ "$PHYNBR" = "1" ] && macaddr_add $addr 1 > /sys${DEVPATH}/macaddress
+               ;;
        wavlink,wl-wn573hx3)
                addr=$(mtd_get_mac_binary factory 0x04)
                [ "$PHYNBR" = "1" ] && macaddr_setbit_la $(macaddr_add $addr -0x300000) > /sys${DEVPATH}/macaddress