summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ti/wlcore/main.c
diff options
context:
space:
mode:
authorArik Nemtsov2012-05-18 06:46:39 +0200
committerLuciano Coelho2012-06-06 18:28:05 +0200
commit2c38849f4a247673c8203a569444042e32d82410 (patch)
tree86b41dd4670f9d1ffa9997cc43ca4565a5050c2b /drivers/net/wireless/ti/wlcore/main.c
parentwlcore: add stop reason bitmap for waking/starting queues (diff)
downloadkernel-qcow2-linux-2c38849f4a247673c8203a569444042e32d82410.tar.gz
kernel-qcow2-linux-2c38849f4a247673c8203a569444042e32d82410.tar.xz
kernel-qcow2-linux-2c38849f4a247673c8203a569444042e32d82410.zip
wlcore: stop queues on Tx flush
Stop network queues during Tx flush, and also drop other internal mac80211 packets (mgmt) that may arrive when the queues are stopped. When flush is done all driver queues are clear, forcefully if needed. Protect the Tx flush operation with a new mutex, to prevent concurrency that can mess us queue state. Based on a patch by Eliad Peller <eliad@wizery.com> Signed-off-by: Arik Nemtsov <arik@wizery.com> Signed-off-by: Luciano Coelho <coelho@ti.com>
Diffstat (limited to 'drivers/net/wireless/ti/wlcore/main.c')
-rw-r--r--drivers/net/wireless/ti/wlcore/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/wireless/ti/wlcore/main.c b/drivers/net/wireless/ti/wlcore/main.c
index bbab19a1ce8a..d81c86cbbf71 100644
--- a/drivers/net/wireless/ti/wlcore/main.c
+++ b/drivers/net/wireless/ti/wlcore/main.c
@@ -5148,6 +5148,7 @@ struct ieee80211_hw *wlcore_alloc_hw(size_t priv_size)
wl->state = WL1271_STATE_OFF;
wl->fw_type = WL12XX_FW_TYPE_NONE;
mutex_init(&wl->mutex);
+ mutex_init(&wl->flush_mutex);
order = get_order(WL1271_AGGR_BUFFER_SIZE);
wl->aggr_buf = (u8 *)__get_free_pages(GFP_KERNEL, order);