package/button-hotplug: handle KEY_RESTART and KEY_WPS_BUTTON codes as well
[openwrt.git] / package / mac80211 / patches / 566-ath9k_stbc_support.patch
1 --- a/drivers/net/wireless/ath/ath9k/init.c
2 +++ b/drivers/net/wireless/ath/ath9k/init.c
3 @@ -217,6 +217,12 @@ static void setup_ht_cap(struct ath_soft
4 else
5 max_streams = 2;
6
7 + if (AR_SREV_9280_10_OR_LATER(ah)) {
8 + if (max_streams >= 2)
9 + ht_info->cap |= IEEE80211_HT_CAP_TX_STBC;
10 + ht_info->cap |= (1 << IEEE80211_HT_CAP_RX_STBC_SHIFT);
11 + }
12 +
13 /* set up supported mcs set */
14 memset(&ht_info->mcs, 0, sizeof(ht_info->mcs));
15 tx_streams = count_streams(common->tx_chainmask, max_streams);
16 --- a/drivers/net/wireless/ath/ath9k/mac.h
17 +++ b/drivers/net/wireless/ath/ath9k/mac.h
18 @@ -37,6 +37,8 @@
19 AR_2040_##_index : 0) \
20 |((_series)[_index].RateFlags & ATH9K_RATESERIES_HALFGI ? \
21 AR_GI##_index : 0) \
22 + |((_series)[_index].RateFlags & ATH9K_RATESERIES_STBC ? \
23 + AR_STBC##_index : 0) \
24 |SM((_series)[_index].ChSel, AR_ChainSel##_index))
25
26 #define CCK_SIFS_TIME 10
27 @@ -434,7 +436,10 @@ struct ar5416_desc {
28 #define AR_ChainSel3_S 17
29 #define AR_RTSCTSRate 0x0ff00000
30 #define AR_RTSCTSRate_S 20
31 -#define AR_TxCtlRsvd70 0xf0000000
32 +#define AR_STBC0 0x10000000
33 +#define AR_STBC1 0x20000000
34 +#define AR_STBC2 0x40000000
35 +#define AR_STBC3 0x80000000
36
37 #define AR_TxRSSIAnt00 0x000000ff
38 #define AR_TxRSSIAnt00_S 0
39 @@ -647,6 +652,7 @@ enum ath9k_rx_filter {
40 #define ATH9K_RATESERIES_RTS_CTS 0x0001
41 #define ATH9K_RATESERIES_2040 0x0002
42 #define ATH9K_RATESERIES_HALFGI 0x0004
43 +#define ATH9K_RATESERIES_STBC 0x0008
44
45 struct ath9k_11n_rate_series {
46 u32 Tries;
47 --- a/drivers/net/wireless/ath/ath9k/xmit.c
48 +++ b/drivers/net/wireless/ath/ath9k/xmit.c
49 @@ -1607,6 +1607,8 @@ static void ath_buf_set_rate(struct ath_
50 series[i].Rate = rix | 0x80;
51 series[i].PktDuration = ath_pkt_duration(sc, rix, bf,
52 is_40, is_sgi, is_sp);
53 + if (rix < 8 && (tx_info->flags & IEEE80211_TX_CTL_STBC))
54 + series[i].RateFlags |= ATH9K_RATESERIES_STBC;
55 continue;
56 }
57
This page took 0.047016 seconds and 5 git commands to generate.