Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 278633
b: refs/heads/master
c: 4279425
h: refs/heads/master
i:
  278631: 0e30c5d
v: v3
  • Loading branch information
Nikolay Martynov authored and John W. Linville committed Dec 7, 2011
1 parent dc1c852 commit 4652f13
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 86951359c1ee35dbae5e11d7cd959e2cb8e6051f
refs/heads/master: 4279425cef58808c0cdc616b8fff17c8308617bd
5 changes: 3 additions & 2 deletions trunk/drivers/net/wireless/ath/ath9k/htc_drv_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -808,7 +808,8 @@ void ath9k_htc_ani_work(struct work_struct *work)
}

/* Verify whether we must check ANI */
if ((timestamp - common->ani.checkani_timer) >= ATH_ANI_POLLINTERVAL) {
if (ah->config.enable_ani &&
(timestamp - common->ani.checkani_timer) >= ATH_ANI_POLLINTERVAL) {
aniflag = true;
common->ani.checkani_timer = timestamp;
}
Expand Down Expand Up @@ -838,7 +839,7 @@ void ath9k_htc_ani_work(struct work_struct *work)
* short calibration and long calibration.
*/
cal_interval = ATH_LONG_CALINTERVAL;
if (priv->ah->config.enable_ani)
if (ah->config.enable_ani)
cal_interval = min(cal_interval, (u32)ATH_ANI_POLLINTERVAL);
if (!common->ani.caldone)
cal_interval = min(cal_interval, (u32)short_cal_interval);
Expand Down
6 changes: 5 additions & 1 deletion trunk/drivers/net/wireless/ath/ath9k/hw.c
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@ static int ath9k_hw_post_init(struct ath_hw *ah)
return ecode;
}

if (!AR_SREV_9100(ah) && !AR_SREV_9340(ah)) {
if (ah->config.enable_ani) {
ath9k_hw_ani_setup(ah);
ath9k_hw_ani_init(ah);
}
Expand Down Expand Up @@ -610,6 +610,10 @@ static int __ath9k_hw_init(struct ath_hw *ah)
if (!AR_SREV_9300_20_OR_LATER(ah))
ah->ani_function &= ~ATH9K_ANI_MRC_CCK;

/* disable ANI for 9100 and 9340 */
if (AR_SREV_9100(ah) || AR_SREV_9340(ah))
ah->config.enable_ani = false;

ath9k_hw_init_mode_regs(ah);

if (!ah->is_pciexpress)
Expand Down
5 changes: 3 additions & 2 deletions trunk/drivers/net/wireless/ath/ath9k/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -582,8 +582,9 @@ void ath_ani_calibrate(unsigned long data)
}

/* Verify whether we must check ANI */
if ((timestamp - common->ani.checkani_timer) >=
ah->config.ani_poll_interval) {
if (sc->sc_ah->config.enable_ani
&& (timestamp - common->ani.checkani_timer) >=
ah->config.ani_poll_interval) {
aniflag = true;
common->ani.checkani_timer = timestamp;
}
Expand Down

0 comments on commit 4652f13

Please sign in to comment.