Browse Source

qcacmn: Fill the frequencies in the SCAN req correctly

Out of the list of scan channels passed by the application,
if the driver skips some channels, then the frequency list sent to
firmware was not correctly filled.
For example if supplicant passes channels 1, 6, 11 and we want to skip
1 and 6, then "req->scan_req.chan_list[0] = 0,
req->scan_req.chan_list[1] = 0 and req->scan_req.chan_list[2] = 11".
It should have been "req->scan_req.chan_list[0] = 11"
Fixes the same.

Change-Id: Idcef090169b8848c2576e620aa0fbe93918c219c
CRs-fixed: 2053866
Ajit Pal Singh 7 years ago
parent
commit
7c24ceadfb
1 changed files with 2 additions and 1 deletions
  1. 2 1
      os_if/linux/scan/src/wlan_cfg80211_scan.c

+ 2 - 1
os_if/linux/scan/src/wlan_cfg80211_scan.c

@@ -1018,7 +1018,8 @@ int wlan_cfg80211_scan(struct wlan_objmgr_pdev *pdev,
 #endif
 
 			len += snprintf(chl + len, 5, "%d ", channel);
-			req->scan_req.chan_list[i] = wlan_chan_to_freq(channel);
+			req->scan_req.chan_list[num_chan] =
+				wlan_chan_to_freq(channel);
 			num_chan++;
 		}
 		cfg80211_notice("Channel-List: %s", chl);