]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ath5k: dont use external sleep clock in AP mode
authorBob Copeland <me@bobcopeland.com>
Thu, 21 Jan 2010 04:51:03 +0000 (23:51 -0500)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 1 Apr 2010 23:01:13 +0000 (16:01 -0700)
commit 5d6ce628f986d1a3c523cbb0a5a52095c48cc332 upstream.

When using the external sleep clock in AP mode, the
TSF increments too quickly, causing beacon interval
to be much lower than it is supposed to be, resulting
in lots of beacon-not-ready interrupts.

This fixes http://bugzilla.kernel.org/show_bug.cgi?id=14802.

Signed-off-by: Bob Copeland <me@bobcopeland.com>
Acked-by: Nick Kossifidis <mickflemm@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/net/wireless/ath/ath5k/reset.c

index 62954fc778692dae949ee32c91a4528b3d4a098e..dbc52ee183b24e6e5ad7764ed644524367145258 100644 (file)
@@ -1371,8 +1371,9 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode,
         * Set clocks to 32KHz operation and use an
         * external 32KHz crystal when sleeping if one
         * exists */
-       if (ah->ah_version == AR5K_AR5212)
-                       ath5k_hw_set_sleep_clock(ah, true);
+       if (ah->ah_version == AR5K_AR5212 &&
+           ah->ah_op_mode != NL80211_IFTYPE_AP)
+               ath5k_hw_set_sleep_clock(ah, true);
 
        /*
         * Disable beacons and reset the register