diff options
author | Rajkumar Manoharan <rmanoharan@atheros.com> | 2011-05-06 08:57:46 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-05-10 15:54:45 -0400 |
commit | deb751880af6f2dce6cdc232a7b023f2b58cd815 (patch) | |
tree | d371ce8950e0496fd4af28a76dbf5c701b264e7e /drivers/net/wireless/ath/ath9k/beacon.c | |
parent | 38bb3e9da62f6ebf1c6940d5482f0d6f431dac1c (diff) |
ath9k: avoid enabling interrupts while processing rx
The assumsion is that while processing ath9k tasklet,
interrupts were already disabled and it will be enabled
at the completion of ath9k tasklet. But whenever TSFOOR is raised,
the driver configures the beacon timers after having received a
beacon frame from the AP which inturn enables the interrupts.
Cc: stable@kernel.org
Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/beacon.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/beacon.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/net/wireless/ath/ath9k/beacon.c b/drivers/net/wireless/ath/ath9k/beacon.c index 22cd241a098b..637dbc5f7b67 100644 --- a/drivers/net/wireless/ath/ath9k/beacon.c +++ b/drivers/net/wireless/ath/ath9k/beacon.c | |||
@@ -620,7 +620,13 @@ static void ath_beacon_config_sta(struct ath_softc *sc, | |||
620 | ath9k_hw_disable_interrupts(ah); | 620 | ath9k_hw_disable_interrupts(ah); |
621 | ath9k_hw_set_sta_beacon_timers(ah, &bs); | 621 | ath9k_hw_set_sta_beacon_timers(ah, &bs); |
622 | ah->imask |= ATH9K_INT_BMISS; | 622 | ah->imask |= ATH9K_INT_BMISS; |
623 | ath9k_hw_set_interrupts(ah, ah->imask); | 623 | |
624 | /* | ||
625 | * If the beacon config is called beacause of TSFOOR, | ||
626 | * Interrupts will be enabled back at the end of ath9k_tasklet | ||
627 | */ | ||
628 | if (!(sc->ps_flags & PS_TSFOOR_SYNC)) | ||
629 | ath9k_hw_set_interrupts(ah, ah->imask); | ||
624 | } | 630 | } |
625 | 631 | ||
626 | static void ath_beacon_config_adhoc(struct ath_softc *sc, | 632 | static void ath_beacon_config_adhoc(struct ath_softc *sc, |
@@ -661,7 +667,12 @@ static void ath_beacon_config_adhoc(struct ath_softc *sc, | |||
661 | ath9k_hw_disable_interrupts(ah); | 667 | ath9k_hw_disable_interrupts(ah); |
662 | ath9k_beacon_init(sc, nexttbtt, intval); | 668 | ath9k_beacon_init(sc, nexttbtt, intval); |
663 | sc->beacon.bmisscnt = 0; | 669 | sc->beacon.bmisscnt = 0; |
664 | ath9k_hw_set_interrupts(ah, ah->imask); | 670 | /* |
671 | * If the beacon config is called beacause of TSFOOR, | ||
672 | * Interrupts will be enabled back at the end of ath9k_tasklet | ||
673 | */ | ||
674 | if (!(sc->ps_flags & PS_TSFOOR_SYNC)) | ||
675 | ath9k_hw_set_interrupts(ah, ah->imask); | ||
665 | } | 676 | } |
666 | 677 | ||
667 | static bool ath9k_allow_beacon_config(struct ath_softc *sc, | 678 | static bool ath9k_allow_beacon_config(struct ath_softc *sc, |