Commit e4dcbb37 authored by David Spinadel's avatar David Spinadel Committed by Johannes Berg

mac80211: fix IE buffer len

Remove size of SSID IE from the IE buffer in scan and
sched scan, since this IE isn't added to this buffer.
Reviewed-by: default avatarEliad Peller <eliad@wizery.com>
Reviewed-by: default avatarEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Reviewed-by: default avatarAlexander Bondar <alexander.bondar@intel.com>
Signed-off-by: default avatarDavid Spinadel <david.spinadel@intel.com>
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 802ee9ec
...@@ -472,9 +472,7 @@ static int __ieee80211_start_scan(struct ieee80211_sub_if_data *sdata, ...@@ -472,9 +472,7 @@ static int __ieee80211_start_scan(struct ieee80211_sub_if_data *sdata,
if (local->ops->hw_scan) { if (local->ops->hw_scan) {
u8 *ies; u8 *ies;
local->hw_scan_ies_bufsize = 2 + IEEE80211_MAX_SSID_LEN + local->hw_scan_ies_bufsize = local->scan_ies_len + req->ie_len;
local->scan_ies_len +
req->ie_len;
local->hw_scan_req = kmalloc( local->hw_scan_req = kmalloc(
sizeof(*local->hw_scan_req) + sizeof(*local->hw_scan_req) +
req->n_channels * sizeof(req->channels[0]) + req->n_channels * sizeof(req->channels[0]) +
...@@ -979,8 +977,7 @@ int __ieee80211_request_sched_scan_start(struct ieee80211_sub_if_data *sdata, ...@@ -979,8 +977,7 @@ int __ieee80211_request_sched_scan_start(struct ieee80211_sub_if_data *sdata,
struct cfg80211_chan_def chandef; struct cfg80211_chan_def chandef;
int ret, i, iebufsz; int ret, i, iebufsz;
iebufsz = 2 + IEEE80211_MAX_SSID_LEN + iebufsz = local->scan_ies_len + req->ie_len;
local->scan_ies_len + req->ie_len;
lockdep_assert_held(&local->mtx); lockdep_assert_held(&local->mtx);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment