diff options
author | Gabor Juhos <juhosg@openwrt.org> | 2009-06-20 18:02:14 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-07-24 15:05:26 -0400 |
commit | 1b7e528b2e39bfed37228eedaaf0665196d8ddc9 (patch) | |
tree | b4479284f3cae14b87818733bd96948a2d9ade1f /drivers/net/wireless/ath/ath9k/hw.c | |
parent | da3c821f549419e09b4b64f07d99f52174daae6d (diff) |
ath9k: wake up the chip for TSF reset
If we are in NETWORK SLEEP state, AR_SLP32_TSF_WRITE_STATUS limit
always exceeds in 'ath9k_hw_reset_tsf', because reading of the
AR_SLP3 register always return with the magic 0xdeadbeef value.
Changes-licensed-under: ISC
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/hw.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index b9d1a13ba164..98537698be22 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -3842,6 +3842,7 @@ void ath9k_hw_reset_tsf(struct ath_hw *ah) | |||
3842 | { | 3842 | { |
3843 | int count; | 3843 | int count; |
3844 | 3844 | ||
3845 | ath9k_ps_wakeup(ah->ah_sc); | ||
3845 | count = 0; | 3846 | count = 0; |
3846 | while (REG_READ(ah, AR_SLP32_MODE) & AR_SLP32_TSF_WRITE_STATUS) { | 3847 | while (REG_READ(ah, AR_SLP32_MODE) & AR_SLP32_TSF_WRITE_STATUS) { |
3847 | count++; | 3848 | count++; |
@@ -3853,6 +3854,7 @@ void ath9k_hw_reset_tsf(struct ath_hw *ah) | |||
3853 | udelay(10); | 3854 | udelay(10); |
3854 | } | 3855 | } |
3855 | REG_WRITE(ah, AR_RESET_TSF, AR_RESET_TSF_ONCE); | 3856 | REG_WRITE(ah, AR_RESET_TSF, AR_RESET_TSF_ONCE); |
3857 | ath9k_ps_restore(ah->ah_sc); | ||
3856 | } | 3858 | } |
3857 | 3859 | ||
3858 | bool ath9k_hw_set_tsfadjust(struct ath_hw *ah, u32 setting) | 3860 | bool ath9k_hw_set_tsfadjust(struct ath_hw *ah, u32 setting) |