diff options
author | Felix Baumann <felix.bau@gmx.de> | 2023-04-21 03:07:58 +0200 |
---|---|---|
committer | David Bauer <mail@david-bauer.net> | 2023-04-24 02:57:26 +0200 |
commit | 45cf200b2e22c34f2ae043b87e24230de526fefc (patch) | |
tree | ff0394603fa370d442df823e0961dc54e9f29d5e /target/linux/ramips/mt7621 | |
parent | 097f350aebc542963c7208af4973ff17e01ce76e (diff) | |
download | upstream-45cf200b2e22c34f2ae043b87e24230de526fefc.tar.gz upstream-45cf200b2e22c34f2ae043b87e24230de526fefc.tar.bz2 upstream-45cf200b2e22c34f2ae043b87e24230de526fefc.zip |
ramips: Cudy X6 fixes / improvements
- Correct WiFi MACs, they didn't match oem firmware
- Move nvmem-cells to bdinfo partition and remove &bdinfo reference
- Add OEM device model name R13 to SUPPORTED_DEVICES
This allows sysupgrading from Cudy's OpenWrt fork without force
- Label red_led and use it during failsafe mode and upgrades
MAC addresses as verified by OEM firmware:
use address source
LAN b4:4b:d6:2d:c8:4a label
WAN b4:4b:d6:2d:c8:4b label + 1
2g b4:4b:d6:2d:c8:4a label
5g b6:4b:d6:3d:c8:4a label + LA-Bit set + 4th oktet increased
The label MAC address is found in bdinfo 0xde00.
Signed-off-by: Felix Baumann <felix.bau@gmx.de>
[read wifi mac from flash offset]
Signed-off-by: David Bauer <mail@david-bauer.net>
Diffstat (limited to 'target/linux/ramips/mt7621')
-rw-r--r-- | target/linux/ramips/mt7621/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/target/linux/ramips/mt7621/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac b/target/linux/ramips/mt7621/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac index 30a10423ad..b6337f397b 100644 --- a/target/linux/ramips/mt7621/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac +++ b/target/linux/ramips/mt7621/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac @@ -28,8 +28,9 @@ case "$board" in [ "$PHYNBR" = "1" ] && macaddr_setbit_la $hw_mac_addr > /sys${DEVPATH}/macaddress ;; cudy,x6) - hw_mac_addr="$(mtd_get_mac_binary factory 0x4)" - macaddr_add $hw_mac_addr "$PHYNBR" > /sys${DEVPATH}/macaddress + hw_mac_addr="$(mtd_get_mac_binary bdinfo 0xde00)" + [ "$PHYNBR" = "1" ] && \ + macaddr_setbit_la "$(macaddr_add $hw_mac_addr 0x100000)" > /sys${DEVPATH}/macaddress ;; dlink,dap-x1860-a1) hw_mac_addr="$(mtd_get_mac_binary factory 0x4)" |