Skip to content

Commit

Permalink
mac80211: set QoS capability before changing station state
Browse files Browse the repository at this point in the history
In the upcoming fast-xmit patch, changing station state will
build a header cache based on the station's capabilities, and
as the QoS capability (sta.wme) impacts the header, it needs
to be set before.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
  • Loading branch information
Johannes Berg committed Mar 30, 2015
1 parent 070e176 commit 2c44be8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions net/mac80211/cfg.c
Original file line number Diff line number Diff line change
Expand Up @@ -1059,6 +1059,10 @@ static int sta_apply_parameters(struct ieee80211_local *local,
}
}

if (mask & BIT(NL80211_STA_FLAG_WME) &&
local->hw.queues >= IEEE80211_NUM_ACS)
sta->sta.wme = set & BIT(NL80211_STA_FLAG_WME);

/* auth flags will be set later for TDLS stations */
if (!test_sta_flag(sta, WLAN_STA_TDLS_PEER)) {
ret = sta_apply_auth_flags(local, sta, mask, set);
Expand All @@ -1073,10 +1077,6 @@ static int sta_apply_parameters(struct ieee80211_local *local,
clear_sta_flag(sta, WLAN_STA_SHORT_PREAMBLE);
}

if (mask & BIT(NL80211_STA_FLAG_WME) &&
local->hw.queues >= IEEE80211_NUM_ACS)
sta->sta.wme = set & BIT(NL80211_STA_FLAG_WME);

if (mask & BIT(NL80211_STA_FLAG_MFP)) {
sta->sta.mfp = !!(set & BIT(NL80211_STA_FLAG_MFP));
if (set & BIT(NL80211_STA_FLAG_MFP))
Expand Down

0 comments on commit 2c44be8

Please sign in to comment.