diff options
author | John W. Linville <linville@tuxdriver.com> | 2012-11-19 14:37:43 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-11-19 14:37:43 -0500 |
commit | e56108d92760c89ce21c30aa02588595b9396251 (patch) | |
tree | 74fdba5362746e534b25063192cf645d7d279fbb /net | |
parent | da8fb123b041e487d28f54d3a77a15139cb9e3b9 (diff) | |
parent | 38c1a01cf10c6e4049b4ffbd4a6af655df2a46e1 (diff) |
Merge branch 'for-john' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211
Diffstat (limited to 'net')
-rw-r--r-- | net/core/net-sysfs.c | 20 | ||||
-rw-r--r-- | net/mac80211/ibss.c | 8 |
2 files changed, 24 insertions, 4 deletions
diff --git a/net/core/net-sysfs.c b/net/core/net-sysfs.c index bcf02f608cbf..017a8bacfb27 100644 --- a/net/core/net-sysfs.c +++ b/net/core/net-sysfs.c | |||
@@ -429,6 +429,17 @@ static struct attribute_group netstat_group = { | |||
429 | .name = "statistics", | 429 | .name = "statistics", |
430 | .attrs = netstat_attrs, | 430 | .attrs = netstat_attrs, |
431 | }; | 431 | }; |
432 | |||
433 | #if IS_ENABLED(CONFIG_WIRELESS_EXT) || IS_ENABLED(CONFIG_CFG80211) | ||
434 | static struct attribute *wireless_attrs[] = { | ||
435 | NULL | ||
436 | }; | ||
437 | |||
438 | static struct attribute_group wireless_group = { | ||
439 | .name = "wireless", | ||
440 | .attrs = wireless_attrs, | ||
441 | }; | ||
442 | #endif | ||
432 | #endif /* CONFIG_SYSFS */ | 443 | #endif /* CONFIG_SYSFS */ |
433 | 444 | ||
434 | #ifdef CONFIG_RPS | 445 | #ifdef CONFIG_RPS |
@@ -1409,6 +1420,15 @@ int netdev_register_kobject(struct net_device *net) | |||
1409 | groups++; | 1420 | groups++; |
1410 | 1421 | ||
1411 | *groups++ = &netstat_group; | 1422 | *groups++ = &netstat_group; |
1423 | |||
1424 | #if IS_ENABLED(CONFIG_WIRELESS_EXT) || IS_ENABLED(CONFIG_CFG80211) | ||
1425 | if (net->ieee80211_ptr) | ||
1426 | *groups++ = &wireless_group; | ||
1427 | #if IS_ENABLED(CONFIG_WIRELESS_EXT) | ||
1428 | else if (net->wireless_handlers) | ||
1429 | *groups++ = &wireless_group; | ||
1430 | #endif | ||
1431 | #endif | ||
1412 | #endif /* CONFIG_SYSFS */ | 1432 | #endif /* CONFIG_SYSFS */ |
1413 | 1433 | ||
1414 | error = device_add(dev); | 1434 | error = device_add(dev); |
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c index bf87c70ac6c5..c21e33d1abd0 100644 --- a/net/mac80211/ibss.c +++ b/net/mac80211/ibss.c | |||
@@ -1151,10 +1151,6 @@ int ieee80211_ibss_leave(struct ieee80211_sub_if_data *sdata) | |||
1151 | 1151 | ||
1152 | mutex_lock(&sdata->u.ibss.mtx); | 1152 | mutex_lock(&sdata->u.ibss.mtx); |
1153 | 1153 | ||
1154 | sdata->u.ibss.state = IEEE80211_IBSS_MLME_SEARCH; | ||
1155 | memset(sdata->u.ibss.bssid, 0, ETH_ALEN); | ||
1156 | sdata->u.ibss.ssid_len = 0; | ||
1157 | |||
1158 | active_ibss = ieee80211_sta_active_ibss(sdata); | 1154 | active_ibss = ieee80211_sta_active_ibss(sdata); |
1159 | 1155 | ||
1160 | if (!active_ibss && !is_zero_ether_addr(ifibss->bssid)) { | 1156 | if (!active_ibss && !is_zero_ether_addr(ifibss->bssid)) { |
@@ -1175,6 +1171,10 @@ int ieee80211_ibss_leave(struct ieee80211_sub_if_data *sdata) | |||
1175 | } | 1171 | } |
1176 | } | 1172 | } |
1177 | 1173 | ||
1174 | ifibss->state = IEEE80211_IBSS_MLME_SEARCH; | ||
1175 | memset(ifibss->bssid, 0, ETH_ALEN); | ||
1176 | ifibss->ssid_len = 0; | ||
1177 | |||
1178 | sta_info_flush(sdata->local, sdata); | 1178 | sta_info_flush(sdata->local, sdata); |
1179 | 1179 | ||
1180 | spin_lock_bh(&ifibss->incomplete_lock); | 1180 | spin_lock_bh(&ifibss->incomplete_lock); |