From: Michal Kazior Date: Fri, 29 Jun 2012 10:46:57 +0000 (+0200) Subject: cfg80211: .stop_ap when interface is going down X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=ac800140c20e7ae51117e71289065bedd4930fc2;p=linux-beck.git cfg80211: .stop_ap when interface is going down We'll need this for proper channel tracking (which is going to be needed for channel context accounting and finding matching/active interface combination). Signed-off-by: Michal Kazior Signed-off-by: Johannes Berg --- diff --git a/net/wireless/core.c b/net/wireless/core.c index ddd32afa5f0a..c65f59c952c9 100644 --- a/net/wireless/core.c +++ b/net/wireless/core.c @@ -810,6 +810,9 @@ static int cfg80211_netdev_notifier_call(struct notifier_block *nb, case NL80211_IFTYPE_MESH_POINT: cfg80211_leave_mesh(rdev, dev); break; + case NL80211_IFTYPE_AP: + cfg80211_stop_ap(rdev, dev); + break; default: break; } diff --git a/net/wireless/util.c b/net/wireless/util.c index 316cfd00914f..fc948d0a53f3 100644 --- a/net/wireless/util.c +++ b/net/wireless/util.c @@ -814,6 +814,9 @@ int cfg80211_change_iface(struct cfg80211_registered_device *rdev, dev->ieee80211_ptr->mesh_id_up_len = 0; switch (otype) { + case NL80211_IFTYPE_AP: + cfg80211_stop_ap(rdev, dev); + break; case NL80211_IFTYPE_ADHOC: cfg80211_leave_ibss(rdev, dev, false); break;