aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorNick Kossifidis <mickflemm@gmail.com>2010-11-23 14:24:54 -0500
committerJohn W. Linville <linville@tuxdriver.com>2010-11-30 13:53:22 -0500
commit71ba1c30851575b43ba76b0f9c26ff5567e8136c (patch)
tree36fefe30180f0d6ef8e7c1989339a21ccac79464 /drivers
parent473cae27620c27377e278a6f92aaa483060e3c19 (diff)
ath5k: Always set IFS intervals on reset
* Make sure we always set IFS timings even if no coverage class is set. If we don't we'll miss the needed changes for different bwmodes. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/ath/ath5k/ath5k.h1
-rw-r--r--drivers/net/wireless/ath/ath5k/pcu.c2
-rw-r--r--drivers/net/wireless/ath/ath5k/qcu.c8
3 files changed, 10 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath5k/ath5k.h b/drivers/net/wireless/ath/ath5k/ath5k.h
index ddbbf4c02fe1..e2588308e677 100644
--- a/drivers/net/wireless/ath/ath5k/ath5k.h
+++ b/drivers/net/wireless/ath/ath5k/ath5k.h
@@ -1224,6 +1224,7 @@ int ath5k_eeprom_read_mac(struct ath5k_hw *ah, u8 *mac);
1224/* Helpers */ 1224/* Helpers */
1225int ath5k_hw_get_frame_duration(struct ath5k_hw *ah, 1225int ath5k_hw_get_frame_duration(struct ath5k_hw *ah,
1226 int len, struct ieee80211_rate *rate); 1226 int len, struct ieee80211_rate *rate);
1227unsigned int ath5k_hw_get_default_slottime(struct ath5k_hw *ah);
1227unsigned int ath5k_hw_get_default_sifs(struct ath5k_hw *ah); 1228unsigned int ath5k_hw_get_default_sifs(struct ath5k_hw *ah);
1228extern int ath5k_hw_set_opmode(struct ath5k_hw *ah, enum nl80211_iftype opmode); 1229extern int ath5k_hw_set_opmode(struct ath5k_hw *ah, enum nl80211_iftype opmode);
1229void ath5k_hw_set_coverage_class(struct ath5k_hw *ah, u8 coverage_class); 1230void ath5k_hw_set_coverage_class(struct ath5k_hw *ah, u8 coverage_class);
diff --git a/drivers/net/wireless/ath/ath5k/pcu.c b/drivers/net/wireless/ath/ath5k/pcu.c
index 6af9504cc7f8..e5f2b96a4c63 100644
--- a/drivers/net/wireless/ath/ath5k/pcu.c
+++ b/drivers/net/wireless/ath/ath5k/pcu.c
@@ -129,7 +129,7 @@ int ath5k_hw_get_frame_duration(struct ath5k_hw *ah,
129 * 129 *
130 * @ah: The &struct ath5k_hw 130 * @ah: The &struct ath5k_hw
131 */ 131 */
132static unsigned int ath5k_hw_get_default_slottime(struct ath5k_hw *ah) 132unsigned int ath5k_hw_get_default_slottime(struct ath5k_hw *ah)
133{ 133{
134 struct ieee80211_channel *channel = ah->ah_current_channel; 134 struct ieee80211_channel *channel = ah->ah_current_channel;
135 unsigned int slot_time; 135 unsigned int slot_time;
diff --git a/drivers/net/wireless/ath/ath5k/qcu.c b/drivers/net/wireless/ath/ath5k/qcu.c
index 69bff047a49a..1849eee8235c 100644
--- a/drivers/net/wireless/ath/ath5k/qcu.c
+++ b/drivers/net/wireless/ath/ath5k/qcu.c
@@ -652,5 +652,13 @@ int ath5k_hw_init_queues(struct ath5k_hw *ah)
652 AR5K_REG_ENABLE_BITS(ah, AR5K_DCU_GBL_IFS_MISC, 652 AR5K_REG_ENABLE_BITS(ah, AR5K_DCU_GBL_IFS_MISC,
653 AR5K_DCU_GBL_IFS_MISC_TURBO_MODE); 653 AR5K_DCU_GBL_IFS_MISC_TURBO_MODE);
654 654
655 /* If we didn't set IFS timings through
656 * ath5k_hw_set_coverage_class make sure
657 * we set them here */
658 if (!ah->ah_coverage_class) {
659 unsigned int slot_time = ath5k_hw_get_default_slottime(ah);
660 ath5k_hw_set_ifs_intervals(ah, slot_time);
661 }
662
655 return 0; 663 return 0;
656} 664}