]> git.baikalelectronics.ru Git - kernel.git/commit
ath9k: use config.enable_ani to check if ani should be performed
authorNikolay Martynov <mar.kolya@gmail.com>
Sat, 3 Dec 2011 03:39:16 +0000 (22:39 -0500)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 7 Dec 2011 20:19:38 +0000 (15:19 -0500)
commitdd0ad2a31fa32590a4e713af570bb3d9a450d963
tree4cc4556c75db15f7c17c0c2472eab855d23d11c7
parent3d00102bd12c3552bc3bce32f8bdb7b5c5a8f62b
ath9k: use config.enable_ani to check if ani should be performed

  Currently in ath9k code there is an attempt which is meant to
disable ANI for ar9100 and ar9340. But it doesn't really achieve
this. All it does is disable ANI init and setup (i.e. calls to
ath9k_hw_ani_setup and ath9k_hw_ani_init). Since ath9k_hw_ani_setup is
not called ah->config.ani_poll_interval is never initialized (i.e. it
is always zero) and ath_ani_calibrate always executes ANI procedures
(over uninitialized ANI parameters).
  Moreover, ath_ani_calibrate is being called each 1ms because
common->ani.timer is set to zero interval because
ah->config.ani_poll_interval==0 (and thus smallest value of all
intervals). Normally it should not be called this often.
  This patch changes the code so config.enable_ani is used to check if
ANI should be performed.
  config.enable_ani is initialized to true by default. This patch sets
it to false for ar9100 and ar9340.

Signed-off-by: Nikolay Martynov <mar.kolya@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/htc_drv_main.c
drivers/net/wireless/ath/ath9k/hw.c
drivers/net/wireless/ath/ath9k/main.c