Zero write to AR_WA on ar9300 reset.
I'd found that the WARegVal field of ath_hw structre which are used to avoid reading the AR_WA reg while chip asleep is used before initialization in ath9k_set_reset_reg(). So that on ar9300 the AR_WA reg is zero written when the ath9k_set_reset_reg() is first called from __ath9k_hw_init(). The WARegVal is read back later, bits 14 and 17 are set. So this variable do not hold initial AR_WA reg value but just bits 14 and 17. I do not know the required behaviour but it looks like mistake.
Quoted 7 lines · Alex Hacker
I'd found that the WARegVal field of
ath_hwstructre which are used to avoid reading theAR_WAreg while chip asleep is used before initialization inath9k_set_reset_reg(). So that on ar9300 theAR_WAreg is zero written when theath9k_set_reset_reg()is first called from__ath9k_hw_init(). The WARegVal is read back later, bits 14 and 17 are set. So this variable do not hold initialAR_WAreg value but just bits 14 and 17. I do not know the required behaviour but it looks like mistake.
This commit may be of some help. please read the full code change in the commit, the comments will be helpful.
ommit 9a658d2b5c222b62919ab47b11c907c731ac180a
Author: Luis R. Rodriguez <[email protected]> Date: Mon Jun 21 18:38:47 2010 -0400
ath9k_hw: fix ASPM setting for AR9003
The AR_WA register should not be read when in sleep state so add a variable we can stash its value into for when we need to set it. Additionally the AR_WA_D3_TO_L1_DISABLE_REAL (bit 16) needs to be removed.
Quoted 5 lines
_______________________________________________
ath9k-devel mailing list
ath9k-devel at lists.ath9k.org
https://lists.ath9k.org/mailman/listinfo/ath9k-devel
I'm sorry just looking in 2.6.38 kernel. I see this is fixed in 2.6.39. Thank you!