summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
diff options
context:
space:
mode:
authorStanislaw Gruszka <sgruszka@redhat.com>2018-09-26 13:24:56 +0300
committerKalle Valo <kvalo@codeaurora.org>2018-10-01 18:37:34 +0300
commitadf26a356f132e35093585521ea3e36cd185af83 (patch)
tree5904ba10dc4634c82f405033cbafbe9484b43164 /drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
parent5022efb50f625d11fdf18b1fee0f64ebb1863664 (diff)
downloadlinux-adf26a356f132e35093585521ea3e36cd185af83.tar.xz
rt2x00: use different txstatus timeouts when flushing
Use different tx status timeouts for normal operation and when flushing. This increase timeout to 2s for normal operation as when there are bad radio conditions and frames are reposted many times device can not provide the status for quite long. With new timeout we can still get valid status on such bad conditions. Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/ralink/rt2x00/rt2x00mac.c')
-rw-r--r--drivers/net/wireless/ralink/rt2x00/rt2x00mac.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
index fa2fd64084ac..2825560e2424 100644
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
@@ -720,8 +720,12 @@ void rt2x00mac_flush(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
if (!test_bit(DEVICE_STATE_PRESENT, &rt2x00dev->flags))
return;
+ set_bit(DEVICE_STATE_FLUSHING, &rt2x00dev->flags);
+
tx_queue_for_each(rt2x00dev, queue)
rt2x00queue_flush_queue(queue, drop);
+
+ clear_bit(DEVICE_STATE_FLUSHING, &rt2x00dev->flags);
}
EXPORT_SYMBOL_GPL(rt2x00mac_flush);