diff options
Diffstat (limited to 'net/mac80211/iface.c')
-rw-r--r-- | net/mac80211/iface.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c index 8acba456744e..4054399be907 100644 --- a/net/mac80211/iface.c +++ b/net/mac80211/iface.c | |||
@@ -382,6 +382,7 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata, | |||
382 | struct sk_buff *skb, *tmp; | 382 | struct sk_buff *skb, *tmp; |
383 | u32 hw_reconf_flags = 0; | 383 | u32 hw_reconf_flags = 0; |
384 | int i; | 384 | int i; |
385 | enum nl80211_channel_type orig_ct; | ||
385 | 386 | ||
386 | if (local->scan_sdata == sdata) | 387 | if (local->scan_sdata == sdata) |
387 | ieee80211_scan_cancel(local); | 388 | ieee80211_scan_cancel(local); |
@@ -542,8 +543,14 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata, | |||
542 | hw_reconf_flags = 0; | 543 | hw_reconf_flags = 0; |
543 | } | 544 | } |
544 | 545 | ||
546 | /* Re-calculate channel-type, in case there are multiple vifs | ||
547 | * on different channel types. | ||
548 | */ | ||
549 | orig_ct = local->_oper_channel_type; | ||
550 | ieee80211_set_channel_type(local, NULL, NL80211_CHAN_NO_HT); | ||
551 | |||
545 | /* do after stop to avoid reconfiguring when we stop anyway */ | 552 | /* do after stop to avoid reconfiguring when we stop anyway */ |
546 | if (hw_reconf_flags) | 553 | if (hw_reconf_flags || (orig_ct != local->_oper_channel_type)) |
547 | ieee80211_hw_config(local, hw_reconf_flags); | 554 | ieee80211_hw_config(local, hw_reconf_flags); |
548 | 555 | ||
549 | spin_lock_irqsave(&local->queue_stop_reason_lock, flags); | 556 | spin_lock_irqsave(&local->queue_stop_reason_lock, flags); |
@@ -1229,6 +1236,7 @@ void ieee80211_remove_interfaces(struct ieee80211_local *local) | |||
1229 | } | 1236 | } |
1230 | mutex_unlock(&local->iflist_mtx); | 1237 | mutex_unlock(&local->iflist_mtx); |
1231 | unregister_netdevice_many(&unreg_list); | 1238 | unregister_netdevice_many(&unreg_list); |
1239 | list_del(&unreg_list); | ||
1232 | } | 1240 | } |
1233 | 1241 | ||
1234 | static u32 ieee80211_idle_off(struct ieee80211_local *local, | 1242 | static u32 ieee80211_idle_off(struct ieee80211_local *local, |