aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ipq806x/base-files/etc/hotplug.d
diff options
context:
space:
mode:
authorStefan Lippers-Hollmann <s.l-h@gmx.de>2017-10-30 04:28:34 +0100
committerMathias Kresin <dev@kresin.me>2017-11-03 20:04:51 +0100
commit189433e543747b1f2191b38f9ffd397de268ceb7 (patch)
treee5f2675cf9d16457618a90b73c104f4930307823 /target/linux/ipq806x/base-files/etc/hotplug.d
parent6e6d4f2e871d9c2eaac728ebe9e6dd8aeb3fb9c9 (diff)
downloadupstream-189433e543747b1f2191b38f9ffd397de268ceb7.tar.gz
upstream-189433e543747b1f2191b38f9ffd397de268ceb7.tar.bz2
upstream-189433e543747b1f2191b38f9ffd397de268ceb7.zip
ipq806x: nbg6817: sync MAC addresses to the upstream values
The ZyXEL NBG6817 calculates all MAC addresses based on the ethaddr value stored in the U-Boot environment (0:APPSBLENV). No MAC addresses are stored in the ART partition and the generated MAC addresses for the wlan interfaces alternate randomly between 12:34:56:78:90:12 and 00:03:7f:12:34:56. interface new/ OEM MAC old MAC wlan-2.4g (phy1): ethaddr undefined wlan-5g (phy0): ethaddr + 1 undefined lan : ethaddr + 2 ethaddr wan : ethaddr + 3 ethaddr + 1 This patch defines stable MAC addresses for the wlan interfaces for the first time instead of generating them at random. The previously defined values for lan/ wan are changed to follow the settings of the OEM firmware. Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de>
Diffstat (limited to 'target/linux/ipq806x/base-files/etc/hotplug.d')
-rw-r--r--target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac3
1 files changed, 3 insertions, 0 deletions
diff --git a/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac b/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
index fee56cd661..7884f5117a 100644
--- a/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
+++ b/target/linux/ipq806x/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
@@ -23,6 +23,9 @@ case "$board" in
ea8500)
echo $(macaddr_add $(mtd_get_mac_ascii devinfo hw_mac_addr) $(($PHYNBR + 1)) ) > /sys${DEVPATH}/macaddress
;;
+ nbg6817)
+ echo $(macaddr_add $(mtd_get_mac_ascii 0:APPSBLENV ethaddr) $((1 - $PHYNBR)) ) > /sys${DEVPATH}/macaddress
+ ;;
vr2600v)
echo $(macaddr_add $(mtd_get_mac_binary default-mac 0) $(($PHYNBR - 1)) ) > /sys${DEVPATH}/macaddress
;;