aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac')
-rw-r--r--target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac20
1 files changed, 20 insertions, 0 deletions
diff --git a/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac b/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac
new file mode 100644
index 0000000000..3092cebfc9
--- /dev/null
+++ b/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac
@@ -0,0 +1,20 @@
+#!/bin/ash
+
+[ "$ACTION" == "add" ] || exit 0
+
+PHYNBR=${DEVPATH##*/phy}
+
+[ -n $PHYNBR ] || exit 0
+
+. /lib/functions.sh
+. /lib/functions/system.sh
+
+board=$(board_name)
+
+case "$board" in
+sophos,red-15w-rev1)
+ echo $(mtd_get_mac_ascii u-boot-env ethaddr) > /sys${DEVPATH}/macaddress
+ ;;
+*)
+ ;;
+esac