diff options
Diffstat (limited to 'target/linux/ath79/nand/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac')
-rw-r--r-- | target/linux/ath79/nand/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/target/linux/ath79/nand/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac b/target/linux/ath79/nand/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac new file mode 100644 index 0000000000..6c61e5df00 --- /dev/null +++ b/target/linux/ath79/nand/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac @@ -0,0 +1,18 @@ +[ "$ACTION" = "add" ] || exit 0 + +PHYNBR=${DEVPATH##*/phy} + +[ -n $PHYNBR ] || exit 0 + +. /lib/functions.sh +. /lib/functions/system.sh + +board=$(board_name) + +case $board in + zyxel,nbg6716) + # Set mac address for 2.4g device + [ "$PHYNBR" -eq 1 ] && \ + mtd_get_mac_ascii u-boot-env ethaddr > /sys${DEVPATH}/macaddress + ;; +esac |