mac80211: move QoS-enable to BSS info
Ever since
commit e1b3ec1a2a
Author: Stanislaw Gruszka <sgruszka@redhat.com>
Date: Mon Mar 29 12:18:34 2010 +0200
mac80211: explicitly disable/enable QoS
mac80211 is telling drivers, in particular
iwlwifi, whether QoS is enabled or not.
However, this is only relevant for station mode,
since only then will any device send nullfunc
frames and need to know whether they should be
QoS frames or not. In other modes, there are
(currently) no frames the device is supposed to
send.
When you now consider virtual interfaces, it
becomes apparent that the current mechanism is
inadequate since it enables/disables QoS on a
global scale, where for nullfunc frames it has
to be on a per-interface scale.
Due to the above considerations, we can change
the way mac80211 advertises the QoS state to
drivers to only ever advertise it as "off" in
station mode, and make it a per-BSS setting.
Tested-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
committed by
John W. Linville
parent
875ae5f688
commit
4ced3f74da
@ -698,10 +698,11 @@ void ieee80211_dynamic_ps_timer(unsigned long data)
|
||||
|
||||
/* MLME */
|
||||
static void ieee80211_sta_wmm_params(struct ieee80211_local *local,
|
||||
struct ieee80211_if_managed *ifmgd,
|
||||
struct ieee80211_sub_if_data *sdata,
|
||||
u8 *wmm_param, size_t wmm_param_len)
|
||||
{
|
||||
struct ieee80211_tx_queue_params params;
|
||||
struct ieee80211_if_managed *ifmgd = &sdata->u.mgd;
|
||||
size_t left;
|
||||
int count;
|
||||
u8 *pos, uapsd_queues = 0;
|
||||
@ -790,8 +791,8 @@ static void ieee80211_sta_wmm_params(struct ieee80211_local *local,
|
||||
}
|
||||
|
||||
/* enable WMM or activate new settings */
|
||||
local->hw.conf.flags |= IEEE80211_CONF_QOS;
|
||||
drv_config(local, IEEE80211_CONF_CHANGE_QOS);
|
||||
sdata->vif.bss_conf.qos = true;
|
||||
ieee80211_bss_info_change_notify(sdata, BSS_CHANGED_QOS);
|
||||
}
|
||||
|
||||
static u32 ieee80211_handle_bss_capability(struct ieee80211_sub_if_data *sdata,
|
||||
@ -1325,7 +1326,7 @@ static bool ieee80211_assoc_success(struct ieee80211_work *wk,
|
||||
}
|
||||
|
||||
if (elems.wmm_param)
|
||||
ieee80211_sta_wmm_params(local, ifmgd, elems.wmm_param,
|
||||
ieee80211_sta_wmm_params(local, sdata, elems.wmm_param,
|
||||
elems.wmm_param_len);
|
||||
else
|
||||
ieee80211_set_wmm_default(sdata);
|
||||
@ -1597,7 +1598,7 @@ static void ieee80211_rx_mgmt_beacon(struct ieee80211_sub_if_data *sdata,
|
||||
ieee80211_rx_bss_info(sdata, mgmt, len, rx_status, &elems,
|
||||
true);
|
||||
|
||||
ieee80211_sta_wmm_params(local, ifmgd, elems.wmm_param,
|
||||
ieee80211_sta_wmm_params(local, sdata, elems.wmm_param,
|
||||
elems.wmm_param_len);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user