mirror of
https://github.com/openwrt/openwrt.git
synced 2025-01-07 14:28:50 +00:00
2c60de0e3f
This unifies MAC address patch functions and moves them to a common script. While those were implemented differently for different targets, they all seem to do the same. The number of different variants is significantly reduced by this patch. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
22 lines
460 B
Bash
22 lines
460 B
Bash
#!/bin/sh
|
|
# Based on ar71xx 11-ath10k-caldata and 10-rt2x00-eeprom
|
|
|
|
[ -e /lib/firmware/$FIRMWARE ] && exit 0
|
|
|
|
. /lib/functions/caldata.sh
|
|
|
|
case "$FIRMWARE" in
|
|
"ath10k/cal-pci-0000:02:00.0.bin")
|
|
board=$(board_name)
|
|
case $board in
|
|
bt,homehub-v5a)
|
|
caldata_extract_ubi "caldata" 0x5000 0x844
|
|
ath10kcal_patch_mac $(macaddr_add $(mtd_get_mac_binary_ubi caldata 0x110c) +3)
|
|
;;
|
|
*)
|
|
caldata_die "board $board is not supported yet"
|
|
;;
|
|
esac
|
|
;;
|
|
esac
|