aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
authorBruno Randolf <br1@einfach.org>2010-09-16 22:36:46 -0400
committerJohn W. Linville <linville@tuxdriver.com>2010-09-21 11:05:10 -0400
commit651d9375dca9997ef2b05639191756da73b0cf8d (patch)
tree64666ca0bcd3723e1415bbd540a50fc81f4441e5 /drivers/net/wireless
parentcfddc11c429a655e418ffc111372cc69dee6a1a5 (diff)
ath5k: Fix TX queues stopping
It does not make sense to stop queues for NF calibration. This will not stop transmissions from the card, if there are queued packets. If we run out of TX buffers we need to stop all queues, not only one. Signed-off-by: Bruno Randolf <br1@einfach.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/ath/ath5k/base.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c
index 776f415e8567..92d139bbcc31 100644
--- a/drivers/net/wireless/ath/ath5k/base.c
+++ b/drivers/net/wireless/ath/ath5k/base.c
@@ -1489,7 +1489,7 @@ static int ath5k_tx_queue(struct ieee80211_hw *hw, struct sk_buff *skb,
1489 if (list_empty(&sc->txbuf)) { 1489 if (list_empty(&sc->txbuf)) {
1490 ATH5K_ERR(sc, "no further txbuf available, dropping packet\n"); 1490 ATH5K_ERR(sc, "no further txbuf available, dropping packet\n");
1491 spin_unlock_irqrestore(&sc->txbuflock, flags); 1491 spin_unlock_irqrestore(&sc->txbuflock, flags);
1492 ieee80211_stop_queue(hw, skb_get_queue_mapping(skb)); 1492 ieee80211_stop_queues(hw);
1493 goto drop_packet; 1493 goto drop_packet;
1494 } 1494 }
1495 bf = list_first_entry(&sc->txbuf, struct ath5k_buf, list); 1495 bf = list_first_entry(&sc->txbuf, struct ath5k_buf, list);
@@ -2138,14 +2138,13 @@ ath5k_tasklet_calibrate(unsigned long data)
2138 sc->curchan->center_freq)); 2138 sc->curchan->center_freq));
2139 2139
2140 /* Noise floor calibration interrupts rx/tx path while I/Q calibration 2140 /* Noise floor calibration interrupts rx/tx path while I/Q calibration
2141 * doesn't. We stop the queues so that calibration doesn't interfere 2141 * doesn't.
2142 * with TX and don't run it as often */ 2142 * TODO: We should stop TX here, so that it doesn't interfere.
2143 * Note that stopping the queues is not enough to stop TX! */
2143 if (time_is_before_eq_jiffies(ah->ah_cal_next_nf)) { 2144 if (time_is_before_eq_jiffies(ah->ah_cal_next_nf)) {
2144 ah->ah_cal_next_nf = jiffies + 2145 ah->ah_cal_next_nf = jiffies +
2145 msecs_to_jiffies(ATH5K_TUNE_CALIBRATION_INTERVAL_NF); 2146 msecs_to_jiffies(ATH5K_TUNE_CALIBRATION_INTERVAL_NF);
2146 ieee80211_stop_queues(sc->hw);
2147 ath5k_hw_update_noise_floor(ah); 2147 ath5k_hw_update_noise_floor(ah);
2148 ieee80211_wake_queues(sc->hw);
2149 } 2148 }
2150 2149
2151 ah->ah_cal_mask &= ~AR5K_CALIBRATION_FULL; 2150 ah->ah_cal_mask &= ~AR5K_CALIBRATION_FULL;