ath9k: merge a fix for the minimum CCA threshold on 5 GHz
[openwrt/openwrt.git] / package / kernel / mac80211 / patches / 323-ath9k-Fix-programming-of-minCCA-power-threshold.patch
1 From: Sven Eckelmann <sven@narfation.org>
2 Date: Fri, 17 Jun 2016 11:58:20 +0200
3 Subject: [PATCH] ath9k: Fix programming of minCCA power threshold
4
5 The function ar9003_hw_apply_minccapwr_thresh takes as second parameter not
6 a pointer to the channel but a boolean value describing whether the channel
7 is 2.4GHz or not. This broke (according to the origin commit) the ETSI
8 regulatory compliance on 5GHz channels.
9
10 Fixes: 3533bf6b15a0 ("ath9k: Fix regulatory compliance")
11 Signed-off-by: Sven Eckelmann <sven@narfation.org>
12 Cc: Simon Wunderlich <sw@simonwunderlich.de>
13 Cc: Sujith Manoharan <c_manoha@qca.qualcomm.com>
14 ---
15
16 --- a/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
17 +++ b/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
18 @@ -4175,7 +4175,7 @@ static void ath9k_hw_ar9300_set_board_va
19 if (!AR_SREV_9330(ah) && !AR_SREV_9340(ah) && !AR_SREV_9531(ah))
20 ar9003_hw_internal_regulator_apply(ah);
21 ar9003_hw_apply_tuning_caps(ah);
22 - ar9003_hw_apply_minccapwr_thresh(ah, chan);
23 + ar9003_hw_apply_minccapwr_thresh(ah, is2ghz);
24 ar9003_hw_txend_to_xpa_off_apply(ah, is2ghz);
25 ar9003_hw_thermometer_apply(ah);
26 ar9003_hw_thermo_cal_apply(ah);