]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - releases/4.18.14/mac80211-allocate-txqs-for-active-monitor-interfaces.patch
4.9-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 4.18.14 / mac80211-allocate-txqs-for-active-monitor-interfaces.patch
1 From 8105f9b8a8879bff7f1d43d0720c993a99c9d135 Mon Sep 17 00:00:00 2001
2 From: Felix Fietkau <nbd@nbd.name>
3 Date: Sat, 22 Sep 2018 18:35:31 +0200
4 Subject: mac80211: allocate TXQs for active monitor interfaces
5
6 From: Felix Fietkau <nbd@nbd.name>
7
8 commit 8105f9b8a8879bff7f1d43d0720c993a99c9d135 upstream.
9
10 Monitor mode interfaces with the active flag are passed down to the driver.
11 Drivers using TXQ expect that all interfaces have allocated TXQs before
12 they get added.
13
14 Fixes: 79af1f866193d ("mac80211: avoid allocating TXQs that won't be used")
15 Cc: stable@vger.kernel.org
16 Reported-by: Catrinel Catrinescu <cc@80211.de>
17 Signed-off-by: Felix Fietkau <nbd@nbd.name>
18 Signed-off-by: Johannes Berg <johannes.berg@intel.com>
19 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
20
21 ---
22 net/mac80211/iface.c | 3 ++-
23 1 file changed, 2 insertions(+), 1 deletion(-)
24
25 --- a/net/mac80211/iface.c
26 +++ b/net/mac80211/iface.c
27 @@ -1756,7 +1756,8 @@ int ieee80211_if_add(struct ieee80211_lo
28
29 if (local->ops->wake_tx_queue &&
30 type != NL80211_IFTYPE_AP_VLAN &&
31 - type != NL80211_IFTYPE_MONITOR)
32 + (type != NL80211_IFTYPE_MONITOR ||
33 + (params->flags & MONITOR_FLAG_ACTIVE)))
34 txq_size += sizeof(struct txq_info) +
35 local->hw.txq_data_size;
36