summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorMartin Willi <martin@strongswan.org>2018-09-25 09:51:02 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-11-04 14:52:38 +0100
commitdb2a11e706bf59d60dbd250f19a383d102a92e69 (patch)
treeec8dbb063846db89b8731c59fe35b4584a45a035 /drivers
parentc7b66583c9edb63ab7613a6ff545367175f95125 (diff)
downloadlinux-stable-db2a11e706bf59d60dbd250f19a383d102a92e69.tar.gz
linux-stable-db2a11e706bf59d60dbd250f19a383d102a92e69.tar.bz2
linux-stable-db2a11e706bf59d60dbd250f19a383d102a92e69.zip
mac80211_hwsim: do not omit multicast announce of first added radio
[ Upstream commit 28ef8b49a338dc1844e86b7954cfffc7dfa2660a ] The allocation of hwsim radio identifiers uses a post-increment from 0, so the first radio has idx 0. This idx is explicitly excluded from multicast announcements ever since, but it is unclear why. Drop that idx check and announce the first radio as well. This makes userspace happy if it relies on these events. Signed-off-by: Martin Willi <martin@strongswan.org> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/mac80211_hwsim.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index aafa7aa18fbd..477f9f2f6626 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -2730,8 +2730,7 @@ static int mac80211_hwsim_new_radio(struct genl_info *info,
list_add_tail(&data->list, &hwsim_radios);
spin_unlock_bh(&hwsim_radio_lock);
- if (idx > 0)
- hwsim_mcast_new_radio(idx, info, param);
+ hwsim_mcast_new_radio(idx, info, param);
return idx;