aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/iface.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2012-12-11 14:38:41 -0500
committerJohannes Berg <johannes.berg@intel.com>2013-01-03 06:59:58 -0500
commit4d76d21bd700fcf72a030ad75c71c816707039b8 (patch)
tree7481ffaf00acb623a272cdf35c612610d57fc825 /net/mac80211/iface.c
parent2d4072a5470621c552f46d51cd54965aeb033893 (diff)
mac80211: assign VLAN channel contexts
Make AP_VLAN type interfaces track the AP master channel context so they have one assigned for the various lookups. Don't give them their own refcount etc. since they're just slaves to the AP master. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/iface.c')
-rw-r--r--net/mac80211/iface.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/net/mac80211/iface.c b/net/mac80211/iface.c
index 09a80b55cf5a..54fb7f9db564 100644
--- a/net/mac80211/iface.c
+++ b/net/mac80211/iface.c
@@ -586,11 +586,13 @@ int ieee80211_do_open(struct wireless_dev *wdev, bool coming_up)
586 586
587 switch (sdata->vif.type) { 587 switch (sdata->vif.type) {
588 case NL80211_IFTYPE_AP_VLAN: 588 case NL80211_IFTYPE_AP_VLAN:
589 /* no need to tell driver, but set carrier */ 589 /* no need to tell driver, but set carrier and chanctx */
590 if (rtnl_dereference(sdata->bss->beacon)) 590 if (rtnl_dereference(sdata->bss->beacon)) {
591 ieee80211_vif_vlan_copy_chanctx(sdata);
591 netif_carrier_on(dev); 592 netif_carrier_on(dev);
592 else 593 } else {
593 netif_carrier_off(dev); 594 netif_carrier_off(dev);
595 }
594 break; 596 break;
595 case NL80211_IFTYPE_MONITOR: 597 case NL80211_IFTYPE_MONITOR:
596 if (sdata->u.mntr_flags & MONITOR_FLAG_COOK_FRAMES) { 598 if (sdata->u.mntr_flags & MONITOR_FLAG_COOK_FRAMES) {
@@ -839,6 +841,7 @@ static void ieee80211_do_stop(struct ieee80211_sub_if_data *sdata,
839 switch (sdata->vif.type) { 841 switch (sdata->vif.type) {
840 case NL80211_IFTYPE_AP_VLAN: 842 case NL80211_IFTYPE_AP_VLAN:
841 list_del(&sdata->u.vlan.list); 843 list_del(&sdata->u.vlan.list);
844 rcu_assign_pointer(sdata->vif.chanctx_conf, NULL);
842 /* no need to tell driver */ 845 /* no need to tell driver */
843 break; 846 break;
844 case NL80211_IFTYPE_MONITOR: 847 case NL80211_IFTYPE_MONITOR: