diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2009-04-23 10:10:04 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-05-06 15:14:33 -0400 |
commit | 57c4d7b4c4986037be51476b8e3025d5ba18d8b8 (patch) | |
tree | bcd24a127b4c79891f45799a20867f49c0f7f949 /net/mac80211/cfg.c | |
parent | f3b85252f081581a8f257545ed748062dce7798b (diff) |
mac80211: clean up beacon interval settings
We currently have two beacon interval configuration knobs:
hw.conf.beacon_int and vif.bss_info.beacon_int. This is
rather confusing, even though the former is used when we
beacon ourselves and the latter when we are associated to
an AP.
This just deprecates the hw.conf.beacon_int setting in favour
of always using vif.bss_info.beacon_int. Since it touches all
the beaconing IBSS code anyway, we can also add support for
the cfg80211 IBSS beacon interval configuration easily.
NOTE: The hw.conf.beacon_int setting is retained for now due
to drivers still using it -- I couldn't untangle all
drivers, some are updated in this patch.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/cfg.c')
-rw-r--r-- | net/mac80211/cfg.c | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index 5e1c230744b5..a898ccd3f2c9 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -451,18 +451,11 @@ static int ieee80211_config_beacon(struct ieee80211_sub_if_data *sdata, | |||
451 | * This is a kludge. beacon interval should really be part | 451 | * This is a kludge. beacon interval should really be part |
452 | * of the beacon information. | 452 | * of the beacon information. |
453 | */ | 453 | */ |
454 | if (params->interval && (sdata->local->hw.conf.beacon_int != | 454 | if (params->interval && |
455 | params->interval)) { | 455 | (sdata->vif.bss_conf.beacon_int != params->interval)) { |
456 | sdata->local->hw.conf.beacon_int = params->interval; | 456 | sdata->vif.bss_conf.beacon_int = params->interval; |
457 | err = ieee80211_hw_config(sdata->local, | 457 | ieee80211_bss_info_change_notify(sdata, |
458 | IEEE80211_CONF_CHANGE_BEACON_INTERVAL); | 458 | BSS_CHANGED_BEACON_INT); |
459 | if (err < 0) | ||
460 | return err; | ||
461 | /* | ||
462 | * We updated some parameter so if below bails out | ||
463 | * it's not an error. | ||
464 | */ | ||
465 | err = 0; | ||
466 | } | 459 | } |
467 | 460 | ||
468 | /* Need to have a beacon head if we don't have one yet */ | 461 | /* Need to have a beacon head if we don't have one yet */ |