summaryrefslogtreecommitdiff
path: root/net/mac80211/ibss.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2009-04-23 16:13:26 +0200
committerJohn W. Linville <linville@tuxdriver.com>2009-05-06 15:14:36 -0400
commit2d0ddec5b2b859f06116f631fc0ffe94fbceb556 (patch)
tree9bf3cdfcbbefcb34f5984e6d797f488ebe358196 /net/mac80211/ibss.c
parent57c4d7b4c4986037be51476b8e3025d5ba18d8b8 (diff)
downloadlwn-2d0ddec5b2b859f06116f631fc0ffe94fbceb556.tar.gz
lwn-2d0ddec5b2b859f06116f631fc0ffe94fbceb556.zip
mac80211: unify config_interface and bss_info_changed
The config_interface method is a little strange, it contains the BSSID and beacon updates, while bss_info_changed contains most other BSS information for each interface. This patch removes config_interface and rolls all the information it previously passed to drivers into bss_info_changed. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/ibss.c')
-rw-r--r--net/mac80211/ibss.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
index f4879dad3cd7..c87caad383f0 100644
--- a/net/mac80211/ibss.c
+++ b/net/mac80211/ibss.c
@@ -95,17 +95,10 @@ static void __ieee80211_sta_join_ibss(struct ieee80211_sub_if_data *sdata,
sdata->drop_unencrypted = capability & WLAN_CAPABILITY_PRIVACY ? 1 : 0;
- ieee80211_if_config(sdata, IEEE80211_IFCC_BSSID);
-
local->oper_channel = chan;
local->oper_channel_type = NL80211_CHAN_NO_HT;
ieee80211_hw_config(local, IEEE80211_CONF_CHANGE_CHANNEL);
- sdata->vif.bss_conf.beacon_int = beacon_int;
- bss_change = BSS_CHANGED_BEACON_INT;
- bss_change |= ieee80211_reset_erp_info(sdata);
- ieee80211_bss_info_change_notify(sdata, bss_change);
-
sband = local->hw.wiphy->bands[chan->band];
/* Build IBSS probe response */
@@ -161,8 +154,13 @@ static void __ieee80211_sta_join_ibss(struct ieee80211_sub_if_data *sdata,
rcu_assign_pointer(ifibss->presp, skb);
- ieee80211_if_config(sdata, IEEE80211_IFCC_BEACON |
- IEEE80211_IFCC_BEACON_ENABLED);
+ sdata->vif.bss_conf.beacon_int = beacon_int;
+ bss_change = BSS_CHANGED_BEACON_INT;
+ bss_change |= ieee80211_reset_erp_info(sdata);
+ bss_change |= BSS_CHANGED_BSSID;
+ bss_change |= BSS_CHANGED_BEACON;
+ bss_change |= BSS_CHANGED_BEACON_ENABLED;
+ ieee80211_bss_info_change_notify(sdata, bss_change);
rates = 0;
for (i = 0; i < supp_rates_len; i++) {
@@ -887,7 +885,7 @@ int ieee80211_ibss_leave(struct ieee80211_sub_if_data *sdata)
kfree(sdata->u.ibss.ie);
skb = sdata->u.ibss.presp;
rcu_assign_pointer(sdata->u.ibss.presp, NULL);
- ieee80211_if_config(sdata, IEEE80211_IFCC_BEACON_ENABLED);
+ ieee80211_bss_info_change_notify(sdata, BSS_CHANGED_BEACON_ENABLED);
synchronize_rcu();
kfree_skb(skb);