aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/util.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2007-12-28 08:32:58 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 18:09:43 -0500
commit471b3efdfccc257591331724145f8ccf8b3217e1 (patch)
treec9e576442c7b62c8c667ae1046e560323f0821fd /net/mac80211/util.c
parent2bc454b0b30b3645d114689b64321cb49be99923 (diff)
mac80211: add unified BSS configuration
This patch (based on Ron Rindjunsky's) creates a framework for a unified way to pass BSS configuration to drivers that require the information, e.g. for implementing power save mode. This patch introduces new ieee80211_bss_conf structure that is passed to the driver via the new bss_info_changed() callback when the BSS configuration changes. This new BSS configuration infrastructure adds the following new features: * drivers are notified of their association AID * drivers are notified of association status and replaces the erp_ie_changed() callback. The patch also does the relevant driver updates for the latter change. Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com> Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/util.c')
-rw-r--r--net/mac80211/util.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index ba81cf542818..5e631ce98d7e 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -312,8 +312,8 @@ __le16 ieee80211_generic_frame_duration(struct ieee80211_hw *hw,
312 int erp; 312 int erp;
313 313
314 erp = ieee80211_is_erp_rate(hw->conf.phymode, rate); 314 erp = ieee80211_is_erp_rate(hw->conf.phymode, rate);
315 dur = ieee80211_frame_duration(local, frame_len, rate, 315 dur = ieee80211_frame_duration(local, frame_len, rate, erp,
316 erp, sdata->flags & IEEE80211_SDATA_SHORT_PREAMBLE); 316 sdata->bss_conf.use_short_preamble);
317 317
318 return cpu_to_le16(dur); 318 return cpu_to_le16(dur);
319} 319}
@@ -326,11 +326,11 @@ __le16 ieee80211_rts_duration(struct ieee80211_hw *hw,
326 struct ieee80211_local *local = hw_to_local(hw); 326 struct ieee80211_local *local = hw_to_local(hw);
327 struct ieee80211_rate *rate; 327 struct ieee80211_rate *rate;
328 struct ieee80211_sub_if_data *sdata = vif_to_sdata(vif); 328 struct ieee80211_sub_if_data *sdata = vif_to_sdata(vif);
329 int short_preamble; 329 bool short_preamble;
330 int erp; 330 int erp;
331 u16 dur; 331 u16 dur;
332 332
333 short_preamble = sdata->flags & IEEE80211_SDATA_SHORT_PREAMBLE; 333 short_preamble = sdata->bss_conf.use_short_preamble;
334 334
335 rate = frame_txctl->rts_rate; 335 rate = frame_txctl->rts_rate;
336 erp = !!(rate->flags & IEEE80211_RATE_ERP); 336 erp = !!(rate->flags & IEEE80211_RATE_ERP);
@@ -357,11 +357,11 @@ __le16 ieee80211_ctstoself_duration(struct ieee80211_hw *hw,
357 struct ieee80211_local *local = hw_to_local(hw); 357 struct ieee80211_local *local = hw_to_local(hw);
358 struct ieee80211_rate *rate; 358 struct ieee80211_rate *rate;
359 struct ieee80211_sub_if_data *sdata = vif_to_sdata(vif); 359 struct ieee80211_sub_if_data *sdata = vif_to_sdata(vif);
360 int short_preamble; 360 bool short_preamble;
361 int erp; 361 int erp;
362 u16 dur; 362 u16 dur;
363 363
364 short_preamble = sdata->flags & IEEE80211_SDATA_SHORT_PREAMBLE; 364 short_preamble = sdata->bss_conf.use_short_preamble;
365 365
366 rate = frame_txctl->rts_rate; 366 rate = frame_txctl->rts_rate;
367 erp = !!(rate->flags & IEEE80211_RATE_ERP); 367 erp = !!(rate->flags & IEEE80211_RATE_ERP);