ath9k: fix key search for a-mpdu on ar9300
[openwrt.git] / package / mac80211 / patches / 530-ath9k_ar9300_keysearch_fix.patch
1 --- a/drivers/net/wireless/ath/ath9k/hw.c
2 +++ b/drivers/net/wireless/ath/ath9k/hw.c
3 @@ -1854,6 +1854,10 @@ int ath9k_hw_fill_cap_info(struct ath_hw
4  
5         ah->misc_mode |= AR_PCU_MIC_NEW_LOC_ENA;
6  
7 +       /* enable key search for every frame in an aggregate */
8 +       if (AR_SREV_9300_20_OR_LATER(ah))
9 +               ah->misc_mode |= AR_PCU_ALWAYS_PERFORM_KEYSEARCH;
10 +
11         pCap->low_2ghz_chan = 2312;
12         pCap->high_2ghz_chan = 2732;
13  
14 --- a/drivers/net/wireless/ath/ath9k/reg.h
15 +++ b/drivers/net/wireless/ath/ath9k/reg.h
16 @@ -1575,6 +1575,7 @@ enum {
17  #define AR_PCU_TBTT_PROTECT        0x00200000
18  #define AR_PCU_CLEAR_VMF           0x01000000
19  #define AR_PCU_CLEAR_BA_VALID      0x04000000
20 +#define AR_PCU_ALWAYS_PERFORM_KEYSEARCH 0x10000000
21  
22  #define AR_PCU_BT_ANT_PREVENT_RX   0x00100000
23  #define AR_PCU_BT_ANT_PREVENT_RX_S 20