aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/mac80211/iface.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c
index 00e2238355f0..ceef64426a8d 100644
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -1703,6 +1703,15 @@ void ieee80211_remove_interfaces(struct ieee80211_local *local)
1703 1703
1704 ASSERT_RTNL(); 1704 ASSERT_RTNL();
1705 1705
1706 /*
1707 * Close all AP_VLAN interfaces first, as otherwise they
1708 * might be closed while the AP interface they belong to
1709 * is closed, causing unregister_netdevice_many() to crash.
1710 */
1711 list_for_each_entry(sdata, &local->interfaces, list)
1712 if (sdata->vif.type == NL80211_IFTYPE_AP_VLAN)
1713 dev_close(sdata->dev);
1714
1706 mutex_lock(&local->iflist_mtx); 1715 mutex_lock(&local->iflist_mtx);
1707 list_for_each_entry_safe(sdata, tmp, &local->interfaces, list) { 1716 list_for_each_entry_safe(sdata, tmp, &local->interfaces, list) {
1708 list_del(&sdata->list); 1717 list_del(&sdata->list);