diff options
author | Johannes Berg <johannes.berg@intel.com> | 2017-12-01 14:50:51 +0300 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2017-12-11 14:20:03 +0300 |
commit | c7c477b52c4caa2cfb44bf3841f806d1bf20e0bf (patch) | |
tree | 84b64ef0381f334b309914489b190afc790e4dbd /net/mac80211 | |
parent | 768075ebc238d11900b27975e649286d292eb8cf (diff) | |
download | linux-c7c477b52c4caa2cfb44bf3841f806d1bf20e0bf.tar.xz |
mac80211: don't warn on AID field without top two MSBs set
While the change between 802.11-2012 and 802.11-2016 to move from
requiring APs to set the two top bits to now requiring them to be
cleared was apparently unintentional and will be fixed, clients
should either way assume that the top five bits are reserved and
ignore them.
Implement that in mac80211.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211')
-rw-r--r-- | net/mac80211/mlme.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c index fa0f96c74898..39b660b9a908 100644 --- a/net/mac80211/mlme.c +++ b/net/mac80211/mlme.c @@ -2862,10 +2862,11 @@ static bool ieee80211_assoc_success(struct ieee80211_sub_if_data *sdata, aid = le16_to_cpu(mgmt->u.assoc_resp.aid); capab_info = le16_to_cpu(mgmt->u.assoc_resp.capab_info); - if ((aid & (BIT(15) | BIT(14))) != (BIT(15) | BIT(14))) - sdata_info(sdata, "invalid AID value 0x%x; bits 15:14 not set\n", - aid); - aid &= ~(BIT(15) | BIT(14)); + /* + * The 5 MSB of the AID field are reserved + * (802.11-2016 9.4.1.8 AID field) + */ + aid &= 0x7ff; ifmgd->broken_ap = false; |