diff options
author | Ivo van Doorn <ivdoorn@gmail.com> | 2008-01-06 17:38:34 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 18:09:22 -0500 |
commit | 1230cb83f46731ca4eaa57c480788ed3c9d05935 (patch) | |
tree | 60be0e3211fafdd2d3afba7aa6527badb2e29790 /drivers/net/wireless/rt2x00/rt2x00usb.c | |
parent | 3e34c6dcb36bbd5294cae2654c32e24b9787da3a (diff) |
rt2x00: Always call ieee80211_stop_queue() when return NETDEV_TX_BUSY
Apparently it was possible that ieee80211_stop_queue() was not full while
NETDEV_TX_BUSY was being reported back. I think that is what causing the WARN_ON().
This moves all calls to ieee80211_stop_queue() in rt2x00mac.c where it is easier
to determine if the queue should be halted.
Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00usb.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2x00usb.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00usb.c b/drivers/net/wireless/rt2x00/rt2x00usb.c index 9778fae313ab..fa0cdd8b3e1a 100644 --- a/drivers/net/wireless/rt2x00/rt2x00usb.c +++ b/drivers/net/wireless/rt2x00/rt2x00usb.c | |||
@@ -179,17 +179,14 @@ int rt2x00usb_write_tx_data(struct rt2x00_dev *rt2x00dev, | |||
179 | struct skb_desc *desc; | 179 | struct skb_desc *desc; |
180 | u32 length; | 180 | u32 length; |
181 | 181 | ||
182 | if (rt2x00_ring_full(ring)) { | 182 | if (rt2x00_ring_full(ring)) |
183 | ieee80211_stop_queue(rt2x00dev->hw, control->queue); | ||
184 | return -EINVAL; | 183 | return -EINVAL; |
185 | } | ||
186 | 184 | ||
187 | if (test_bit(ENTRY_OWNER_NIC, &entry->flags)) { | 185 | if (test_bit(ENTRY_OWNER_NIC, &entry->flags)) { |
188 | ERROR(rt2x00dev, | 186 | ERROR(rt2x00dev, |
189 | "Arrived at non-free entry in the non-full queue %d.\n" | 187 | "Arrived at non-free entry in the non-full queue %d.\n" |
190 | "Please file bug report to %s.\n", | 188 | "Please file bug report to %s.\n", |
191 | control->queue, DRV_PROJECT); | 189 | control->queue, DRV_PROJECT); |
192 | ieee80211_stop_queue(rt2x00dev->hw, control->queue); | ||
193 | return -EINVAL; | 190 | return -EINVAL; |
194 | } | 191 | } |
195 | 192 | ||
@@ -229,9 +226,6 @@ int rt2x00usb_write_tx_data(struct rt2x00_dev *rt2x00dev, | |||
229 | 226 | ||
230 | rt2x00_ring_index_inc(ring); | 227 | rt2x00_ring_index_inc(ring); |
231 | 228 | ||
232 | if (rt2x00_ring_full(ring)) | ||
233 | ieee80211_stop_queue(rt2x00dev->hw, control->queue); | ||
234 | |||
235 | return 0; | 229 | return 0; |
236 | } | 230 | } |
237 | EXPORT_SYMBOL_GPL(rt2x00usb_write_tx_data); | 231 | EXPORT_SYMBOL_GPL(rt2x00usb_write_tx_data); |