aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/nand/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/ath79/nand/base-files/etc/hotplug.d/firmware/11-ath10k-caldata')
-rw-r--r--target/linux/ath79/nand/base-files/etc/hotplug.d/firmware/11-ath10k-caldata22
1 files changed, 22 insertions, 0 deletions
diff --git a/target/linux/ath79/nand/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ath79/nand/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
new file mode 100644
index 0000000000..75fdd42cdd
--- /dev/null
+++ b/target/linux/ath79/nand/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+[ -e /lib/firmware/$FIRMWARE ] && exit 0
+
+. /lib/functions/caldata.sh
+. /lib/functions/k2t.sh
+
+board=$(board_name)
+
+case "$FIRMWARE" in
+"ath10k/cal-pci-0000:00:00.0.bin")
+ case $board in
+ zyxel,nbg6716)
+ caldata_extract "art" 0x5000 0x844
+ ath10kcal_patch_mac $(macaddr_add $(mtd_get_mac_ascii u-boot-env ethaddr) +1)
+ ;;
+ esac
+ ;;
+*)
+ exit 1
+ ;;
+esac