diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2008-07-02 18:27:13 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-07-08 14:16:01 -0400 |
commit | fc32f9243dc93e75f81457e95d9cb90ee6136d94 (patch) | |
tree | b95c2c4ac3cf2052d9bcb67eeac51cfe6fee2a9b /net/mac80211/main.c | |
parent | 8e8862b79d2ce9177bfddd85b8328a86a25c69b2 (diff) |
mac80211: call bss_info_change only once upon disassociation
This patch removes call of ieee80211_bss_info_change_notify from within
ieee80211_reset_erp_info. This allows gathering all bss info changes
into one call to the driver in the disassociation flow.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/main.c')
-rw-r--r-- | net/mac80211/main.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/net/mac80211/main.c b/net/mac80211/main.c index 074f71a62a6d..cc756e93e6c8 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c | |||
@@ -182,10 +182,11 @@ static int ieee80211_open(struct net_device *dev) | |||
182 | { | 182 | { |
183 | struct ieee80211_sub_if_data *sdata, *nsdata; | 183 | struct ieee80211_sub_if_data *sdata, *nsdata; |
184 | struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr); | 184 | struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr); |
185 | struct sta_info *sta; | ||
185 | struct ieee80211_if_init_conf conf; | 186 | struct ieee80211_if_init_conf conf; |
187 | u32 changed = 0; | ||
186 | int res; | 188 | int res; |
187 | bool need_hw_reconfig = 0; | 189 | bool need_hw_reconfig = 0; |
188 | struct sta_info *sta; | ||
189 | 190 | ||
190 | sdata = IEEE80211_DEV_TO_SUB_IF(dev); | 191 | sdata = IEEE80211_DEV_TO_SUB_IF(dev); |
191 | 192 | ||
@@ -329,7 +330,8 @@ static int ieee80211_open(struct net_device *dev) | |||
329 | goto err_stop; | 330 | goto err_stop; |
330 | 331 | ||
331 | ieee80211_if_config(dev); | 332 | ieee80211_if_config(dev); |
332 | ieee80211_reset_erp_info(dev); | 333 | changed |= ieee80211_reset_erp_info(dev); |
334 | ieee80211_bss_info_change_notify(sdata, changed); | ||
333 | ieee80211_enable_keys(sdata); | 335 | ieee80211_enable_keys(sdata); |
334 | 336 | ||
335 | if (sdata->vif.type == IEEE80211_IF_TYPE_STA && | 337 | if (sdata->vif.type == IEEE80211_IF_TYPE_STA && |
@@ -1190,15 +1192,13 @@ void ieee80211_bss_info_change_notify(struct ieee80211_sub_if_data *sdata, | |||
1190 | changed); | 1192 | changed); |
1191 | } | 1193 | } |
1192 | 1194 | ||
1193 | void ieee80211_reset_erp_info(struct net_device *dev) | 1195 | u32 ieee80211_reset_erp_info(struct net_device *dev) |
1194 | { | 1196 | { |
1195 | struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev); | 1197 | struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev); |
1196 | 1198 | ||
1197 | sdata->bss_conf.use_cts_prot = 0; | 1199 | sdata->bss_conf.use_cts_prot = 0; |
1198 | sdata->bss_conf.use_short_preamble = 0; | 1200 | sdata->bss_conf.use_short_preamble = 0; |
1199 | ieee80211_bss_info_change_notify(sdata, | 1201 | return BSS_CHANGED_ERP_CTS_PROT | BSS_CHANGED_ERP_PREAMBLE; |
1200 | BSS_CHANGED_ERP_CTS_PROT | | ||
1201 | BSS_CHANGED_ERP_PREAMBLE); | ||
1202 | } | 1202 | } |
1203 | 1203 | ||
1204 | void ieee80211_tx_status_irqsafe(struct ieee80211_hw *hw, | 1204 | void ieee80211_tx_status_irqsafe(struct ieee80211_hw *hw, |