diff options
author | Arik Nemtsov <arik@wizery.com> | 2014-06-11 10:18:19 -0400 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2014-06-23 08:24:55 -0400 |
commit | 68885a54cd04742a2e6e10e9d3ff5976d046832e (patch) | |
tree | 76bdd966f2c88d2047d5f73f314282da82a17bf9 | |
parent | 9deba04d0f0b43ca60a867f006e06625ad85f8c2 (diff) |
mac80211: set auth flags after other station info
For TDLS, the AUTHORIZED flag arrives with all other important station
info (supported rates, HT/VHT caps, ...). Make sure to set the station
state in the low-level driver after transferring this information to
the mac80211 STA entry.
This aligns the STA information during sta_state callbacks with the
non-TDLS case.
Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r-- | net/mac80211/cfg.c | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index a0d7a0362f1f..73c9e1003e25 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c | |||
@@ -997,9 +997,12 @@ static int sta_apply_parameters(struct ieee80211_local *local, | |||
997 | } | 997 | } |
998 | } | 998 | } |
999 | 999 | ||
1000 | ret = sta_apply_auth_flags(local, sta, mask, set); | 1000 | /* auth flags will be set later for TDLS stations */ |
1001 | if (ret) | 1001 | if (!test_sta_flag(sta, WLAN_STA_TDLS_PEER)) { |
1002 | return ret; | 1002 | ret = sta_apply_auth_flags(local, sta, mask, set); |
1003 | if (ret) | ||
1004 | return ret; | ||
1005 | } | ||
1003 | 1006 | ||
1004 | if (mask & BIT(NL80211_STA_FLAG_SHORT_PREAMBLE)) { | 1007 | if (mask & BIT(NL80211_STA_FLAG_SHORT_PREAMBLE)) { |
1005 | if (set & BIT(NL80211_STA_FLAG_SHORT_PREAMBLE)) | 1008 | if (set & BIT(NL80211_STA_FLAG_SHORT_PREAMBLE)) |
@@ -1136,6 +1139,13 @@ static int sta_apply_parameters(struct ieee80211_local *local, | |||
1136 | #endif | 1139 | #endif |
1137 | } | 1140 | } |
1138 | 1141 | ||
1142 | /* set the STA state after all sta info from usermode has been set */ | ||
1143 | if (test_sta_flag(sta, WLAN_STA_TDLS_PEER)) { | ||
1144 | ret = sta_apply_auth_flags(local, sta, mask, set); | ||
1145 | if (ret) | ||
1146 | return ret; | ||
1147 | } | ||
1148 | |||
1139 | return 0; | 1149 | return 0; |
1140 | } | 1150 | } |
1141 | 1151 | ||