From 67536373d937e1e8fa1c0470da8511b6a5561a10 Mon Sep 17 00:00:00 2001 From: coolsnowwolf Date: Thu, 24 Jan 2019 14:22:27 +0800 Subject: [PATCH] mac80211: ath: add extra 'regulatory domains' for sanitize --- .../407-regulatory-sanitize-extra-codes.patch | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 package/kernel/mac80211/patches/ath/407-regulatory-sanitize-extra-codes.patch diff --git a/package/kernel/mac80211/patches/ath/407-regulatory-sanitize-extra-codes.patch b/package/kernel/mac80211/patches/ath/407-regulatory-sanitize-extra-codes.patch new file mode 100644 index 000000000..95db0d8f1 --- /dev/null +++ b/package/kernel/mac80211/patches/ath/407-regulatory-sanitize-extra-codes.patch @@ -0,0 +1,18 @@ +Index: backports-4.19.7-1/drivers/net/wireless/ath/regd.c +=================================================================== +--- backports-4.19.7-1.orig/drivers/net/wireless/ath/regd.c ++++ backports-4.19.7-1/drivers/net/wireless/ath/regd.c +@@ -703,6 +703,12 @@ ath_regd_init_wiphy(struct ath_regulator + */ + static void ath_regd_sanitize(struct ath_regulatory *reg) + { ++ /* ++ * This will sanitize the following values: ++ * - 0x834b -> in the Linksys EA6350v3 ++ * - 0x8000 -> some manufacturers use this invalid code ++ */ +- if (reg->current_rd != COUNTRY_ERD_FLAG) ++ if (reg->current_rd != COUNTRY_ERD_FLAG && ++ reg->current_rd != 0x834b) + return; + printk(KERN_DEBUG "ath: EEPROM regdomain sanitized\n");