ath79: engenius,esrxxxx: use nvmem for WAN MAC address

When the u-boot-env layout driver probes successfully,
all of the variables are available as NVMEM cells in sysfs,
not just the ones used with a phandle in devicetree.

Use the new function mtd_get_mac_nvmem()
over the older deprecated mtd_get_mac_ascii(),
to avoid an unnecessary read of MTD devices.

Signed-off-by: Michael Pratt <mcpratt@pm.me>
Link: https://github.com/openwrt/openwrt/pull/24866
Signed-off-by: Robert Marko <robimarko@gmail.com>
This commit is contained in:
Michael Pratt authored and Robert Marko committed 2026-11-04 22:34:59 +01:00
1 parent 474e8bd7d7
commit bd742322ea
1 file changed
+1 -1
@@ -724,7 +724,7 @@ ath79_setup_macs()
engenius,esr1200|\
engenius,esr1750|\
engenius,esr900)
wan_mac=$(mtd_get_mac_ascii u-boot-env wanaddr)
wan_mac=$(mtd_get_mac_nvmem u-boot-env wanaddr)
;;
hak5,lan-turtle|\
hak5,packet-squirrel)