Skip to content

Commit

Permalink
ath9k: wake up the chip for TSF reset
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Gabor Juhos authored and John W. Linville committed Jul 24, 2009
1 parent da3c821 commit 1b7e528
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/wireless/ath/ath9k/hw.c
Original file line number Diff line number Diff line change
Expand Up @@ -3842,6 +3842,7 @@ void ath9k_hw_reset_tsf(struct ath_hw *ah)
{
int count;

ath9k_ps_wakeup(ah->ah_sc);
count = 0;
while (REG_READ(ah, AR_SLP32_MODE) & AR_SLP32_TSF_WRITE_STATUS) {
count++;
Expand All @@ -3853,6 +3854,7 @@ void ath9k_hw_reset_tsf(struct ath_hw *ah)
udelay(10);
}
REG_WRITE(ah, AR_RESET_TSF, AR_RESET_TSF_ONCE);
ath9k_ps_restore(ah->ah_sc);
}

bool ath9k_hw_set_tsfadjust(struct ath_hw *ah, u32 setting)
Expand Down

0 comments on commit 1b7e528

Please sign in to comment.