diff options
author | Johannes Berg <johannes.berg@intel.com> | 2013-03-25 17:29:27 (GMT) |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2013-04-16 13:29:44 (GMT) |
commit | 85220d71bf3ca1ba9129e0744247ae5f61bec559 (patch) | |
tree | 5bdabc71bc5da27ee71fb1272b86809ac2f95b0d /net/mac80211/util.c | |
parent | b4f286a1c0ad0b84c2d502b354d4d98d5a86c64b (diff) | |
download | linux-85220d71bf3ca1ba9129e0744247ae5f61bec559.tar.xz |
mac80211: support secondary channel offset in CSA
Add support for the secondary channel offset IE in channel
switch announcements. This is necessary for proper handling
of CSA on HT access points.
For this to work it is also necessary to convert everything
here to use chandef structs instead of just channels. The
driver updates aren't really correct though. In particular,
the TI wl18xx driver update can't possibly be right since
it just ignores the new channel width for lack of firmware
API.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/util.c')
-rw-r--r-- | net/mac80211/util.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/net/mac80211/util.c b/net/mac80211/util.c index e4a6d55..155056c 100644 --- a/net/mac80211/util.c +++ b/net/mac80211/util.c @@ -716,6 +716,7 @@ u32 ieee802_11_parse_elems_crc(u8 *start, size_t len, case WLAN_EID_COUNTRY: case WLAN_EID_PWR_CONSTRAINT: case WLAN_EID_TIMEOUT_INTERVAL: + case WLAN_EID_SECONDARY_CHANNEL_OFFSET: if (test_bit(id, seen_elems)) { elems->parse_error = true; left -= elen; @@ -870,6 +871,13 @@ u32 ieee802_11_parse_elems_crc(u8 *start, size_t len, } elems->ext_chansw_ie = (void *)pos; break; + case WLAN_EID_SECONDARY_CHANNEL_OFFSET: + if (elen != sizeof(struct ieee80211_sec_chan_offs_ie)) { + elem_parse_failed = true; + break; + } + elems->sec_chan_offs = (void *)pos; + break; case WLAN_EID_COUNTRY: elems->country_elem = pos; elems->country_elem_len = elen; |