diff options
author | Vasanthakumar Thiagarajan <vasanth@atheros.com> | 2009-08-31 08:18:36 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-08-31 14:42:15 -0400 |
commit | 1c29ce672fe817c208309eea0c1ff7bf76250f15 (patch) | |
tree | 4f01db66751551ce2089faf67bb4fcb49c750d67 /drivers/net | |
parent | 3107edbae8216a80920bed7f8d4ec2e6b62390f2 (diff) |
ath9k: Do an AHB reset before doing RTC reset
Doing an RTC reset when DMA is active may corrupt memory,
make sure no DMA is active at this moment by doing an
AHB reset.
Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index e340dacc6ebe..71f27f324cea 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -1712,8 +1712,15 @@ static bool ath9k_hw_set_reset_power_on(struct ath_hw *ah) | |||
1712 | REG_WRITE(ah, AR_RTC_FORCE_WAKE, AR_RTC_FORCE_WAKE_EN | | 1712 | REG_WRITE(ah, AR_RTC_FORCE_WAKE, AR_RTC_FORCE_WAKE_EN | |
1713 | AR_RTC_FORCE_WAKE_ON_INT); | 1713 | AR_RTC_FORCE_WAKE_ON_INT); |
1714 | 1714 | ||
1715 | if (!AR_SREV_9100(ah)) | ||
1716 | REG_WRITE(ah, AR_RC, AR_RC_AHB); | ||
1717 | |||
1715 | REG_WRITE(ah, AR_RTC_RESET, 0); | 1718 | REG_WRITE(ah, AR_RTC_RESET, 0); |
1716 | udelay(2); | 1719 | udelay(2); |
1720 | |||
1721 | if (!AR_SREV_9100(ah)) | ||
1722 | REG_WRITE(ah, AR_RC, 0); | ||
1723 | |||
1717 | REG_WRITE(ah, AR_RTC_RESET, 1); | 1724 | REG_WRITE(ah, AR_RTC_RESET, 1); |
1718 | 1725 | ||
1719 | if (!ath9k_hw_wait(ah, | 1726 | if (!ath9k_hw_wait(ah, |