diff options
author | Sujith <Sujith.Manoharan@atheros.com> | 2009-09-03 02:38:43 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-09-08 16:31:05 -0400 |
commit | 7ea310be65bfcbc6e2395844fd3498762dc2aea6 (patch) | |
tree | 78bf6a77bfd2591429a50b0e907563884bdcc72e /drivers/net/wireless/ath | |
parent | fc548af877374f7e26c4f670f3843c6d29e02a98 (diff) |
ath9k: Fix RX Filter handling for BAR
BAR frames have to be sent to mac80211 only if the
current channel is HT. Also, move the macro to
enum ath9k_rx_filter.
Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/mac.h | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/recv.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/reg.h | 1 |
5 files changed, 7 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 71f27f324cea..011b14f35e50 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -3967,7 +3967,8 @@ void ath9k_hw_setrxfilter(struct ath_hw *ah, u32 bits) | |||
3967 | { | 3967 | { |
3968 | u32 phybits; | 3968 | u32 phybits; |
3969 | 3969 | ||
3970 | REG_WRITE(ah, AR_RX_FILTER, (bits & 0xffff) | AR_RX_COMPR_BAR); | 3970 | REG_WRITE(ah, AR_RX_FILTER, bits); |
3971 | |||
3971 | phybits = 0; | 3972 | phybits = 0; |
3972 | if (bits & ATH9K_RX_FILTER_PHYRADAR) | 3973 | if (bits & ATH9K_RX_FILTER_PHYRADAR) |
3973 | phybits |= AR_PHY_ERR_RADAR; | 3974 | phybits |= AR_PHY_ERR_RADAR; |
diff --git a/drivers/net/wireless/ath/ath9k/mac.h b/drivers/net/wireless/ath/ath9k/mac.h index 7b3982295a43..f56e77da6c3e 100644 --- a/drivers/net/wireless/ath/ath9k/mac.h +++ b/drivers/net/wireless/ath/ath9k/mac.h | |||
@@ -568,6 +568,7 @@ enum ath9k_rx_filter { | |||
568 | ATH9K_RX_FILTER_PROBEREQ = 0x00000080, | 568 | ATH9K_RX_FILTER_PROBEREQ = 0x00000080, |
569 | ATH9K_RX_FILTER_PHYERR = 0x00000100, | 569 | ATH9K_RX_FILTER_PHYERR = 0x00000100, |
570 | ATH9K_RX_FILTER_MYBEACON = 0x00000200, | 570 | ATH9K_RX_FILTER_MYBEACON = 0x00000200, |
571 | ATH9K_RX_FILTER_COMP_BAR = 0x00000400, | ||
571 | ATH9K_RX_FILTER_PSPOLL = 0x00004000, | 572 | ATH9K_RX_FILTER_PSPOLL = 0x00004000, |
572 | ATH9K_RX_FILTER_PHYRADAR = 0x00002000, | 573 | ATH9K_RX_FILTER_PHYRADAR = 0x00002000, |
573 | ATH9K_RX_FILTER_MCAST_BCAST_ALL = 0x00008000, | 574 | ATH9K_RX_FILTER_MCAST_BCAST_ALL = 0x00008000, |
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index c2efdf2d72d3..b1d189c6be8a 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c | |||
@@ -2433,7 +2433,7 @@ static void ath9k_configure_filter(struct ieee80211_hw *hw, | |||
2433 | ath9k_hw_setrxfilter(sc->sc_ah, rfilt); | 2433 | ath9k_hw_setrxfilter(sc->sc_ah, rfilt); |
2434 | ath9k_ps_restore(sc); | 2434 | ath9k_ps_restore(sc); |
2435 | 2435 | ||
2436 | DPRINTF(sc, ATH_DBG_CONFIG, "Set HW RX filter: 0x%x\n", sc->rx.rxfilter); | 2436 | DPRINTF(sc, ATH_DBG_CONFIG, "Set HW RX filter: 0x%x\n", rfilt); |
2437 | } | 2437 | } |
2438 | 2438 | ||
2439 | static void ath9k_sta_notify(struct ieee80211_hw *hw, | 2439 | static void ath9k_sta_notify(struct ieee80211_hw *hw, |
diff --git a/drivers/net/wireless/ath/ath9k/recv.c b/drivers/net/wireless/ath/ath9k/recv.c index 52e62daad3ce..ec0abf823995 100644 --- a/drivers/net/wireless/ath/ath9k/recv.c +++ b/drivers/net/wireless/ath/ath9k/recv.c | |||
@@ -423,6 +423,9 @@ u32 ath_calcrxfilter(struct ath_softc *sc) | |||
423 | if (sc->rx.rxfilter & FIF_PSPOLL) | 423 | if (sc->rx.rxfilter & FIF_PSPOLL) |
424 | rfilt |= ATH9K_RX_FILTER_PSPOLL; | 424 | rfilt |= ATH9K_RX_FILTER_PSPOLL; |
425 | 425 | ||
426 | if (conf_is_ht(&sc->hw->conf)) | ||
427 | rfilt |= ATH9K_RX_FILTER_COMP_BAR; | ||
428 | |||
426 | if (sc->sec_wiphy || (sc->rx.rxfilter & FIF_OTHER_BSS)) { | 429 | if (sc->sec_wiphy || (sc->rx.rxfilter & FIF_OTHER_BSS)) { |
427 | /* TODO: only needed if more than one BSSID is in use in | 430 | /* TODO: only needed if more than one BSSID is in use in |
428 | * station/adhoc mode */ | 431 | * station/adhoc mode */ |
diff --git a/drivers/net/wireless/ath/ath9k/reg.h b/drivers/net/wireless/ath/ath9k/reg.h index 3ddb243f0000..e5c29eb86e80 100644 --- a/drivers/net/wireless/ath/ath9k/reg.h +++ b/drivers/net/wireless/ath/ath9k/reg.h | |||
@@ -1325,7 +1325,6 @@ enum { | |||
1325 | #define AR_CFP_VAL 0x0000FFFF | 1325 | #define AR_CFP_VAL 0x0000FFFF |
1326 | 1326 | ||
1327 | #define AR_RX_FILTER 0x803C | 1327 | #define AR_RX_FILTER 0x803C |
1328 | #define AR_RX_COMPR_BAR 0x00000400 | ||
1329 | 1328 | ||
1330 | #define AR_MCAST_FIL0 0x8040 | 1329 | #define AR_MCAST_FIL0 0x8040 |
1331 | #define AR_MCAST_FIL1 0x8044 | 1330 | #define AR_MCAST_FIL1 0x8044 |