diff options
author | Christian Lamparter <chunkeey@googlemail.com> | 2010-12-30 11:25:29 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-01-04 14:46:13 -0500 |
commit | 24a8fdad35835e8d71f7c4b978a246fafed2e7b4 (patch) | |
tree | 3ee2b5710b802dca6fe43cbedf461c54e0f2be93 /net/mac80211/main.c | |
parent | 1186488b4a4d4871e40cb1604ba3ede3d4b7cc90 (diff) |
mac80211: serialize rx path workers
This patch addresses the issue of serialization between
the main rx path and various reorder release timers.
<http://www.spinics.net/lists/linux-wireless/msg57214.html>
It converts the previously local "frames" queue into
a global rx queue [rx_skb_queue]. This way, everyone
(be it the main rx-path or some reorder release timeout)
can add frames to it.
Only one active rx handler worker [ieee80211_rx_handlers]
is needed. All other threads which have lost the race of
"runnning_rx_handler" can now simply "return", knowing that
the thread who had the "edge" will also take care of their
workload.
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/main.c')
-rw-r--r-- | net/mac80211/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/net/mac80211/main.c b/net/mac80211/main.c index a21d049caf19..32e7ae0dac98 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c | |||
@@ -569,6 +569,8 @@ struct ieee80211_hw *ieee80211_alloc_hw(size_t priv_data_len, | |||
569 | spin_lock_init(&local->filter_lock); | 569 | spin_lock_init(&local->filter_lock); |
570 | spin_lock_init(&local->queue_stop_reason_lock); | 570 | spin_lock_init(&local->queue_stop_reason_lock); |
571 | 571 | ||
572 | skb_queue_head_init(&local->rx_skb_queue); | ||
573 | |||
572 | INIT_DELAYED_WORK(&local->scan_work, ieee80211_scan_work); | 574 | INIT_DELAYED_WORK(&local->scan_work, ieee80211_scan_work); |
573 | 575 | ||
574 | ieee80211_work_init(local); | 576 | ieee80211_work_init(local); |
@@ -912,6 +914,7 @@ void ieee80211_unregister_hw(struct ieee80211_hw *hw) | |||
912 | wiphy_warn(local->hw.wiphy, "skb_queue not empty\n"); | 914 | wiphy_warn(local->hw.wiphy, "skb_queue not empty\n"); |
913 | skb_queue_purge(&local->skb_queue); | 915 | skb_queue_purge(&local->skb_queue); |
914 | skb_queue_purge(&local->skb_queue_unreliable); | 916 | skb_queue_purge(&local->skb_queue_unreliable); |
917 | skb_queue_purge(&local->rx_skb_queue); | ||
915 | 918 | ||
916 | destroy_workqueue(local->workqueue); | 919 | destroy_workqueue(local->workqueue); |
917 | wiphy_unregister(local->hw.wiphy); | 920 | wiphy_unregister(local->hw.wiphy); |