Browse Source

qcacld-3.0: Fix station scan AP failed in SAP+STA mode

qcacld-2.0 to qcacld-3.0 propagation

If SAP interface is up then STA interface can't find
the AP most of the time as a result of SCAN parameters
are getting set to 28ms active dwell time and 0
repeated probe (which means only 1 probe for 28ms of
active dwell time).

Test results suggest that 1 Probe request through out
the active dwell time in noisy environment is not good
enough, so sending two probe requests with each 11ms
apart would make the scan results little better.

Implement above suggested solution by changing
probe_time_dwell_time_map's repeated probe time to
11ms so that n_probes (number of probes) becomes 2
by n_probes = (dwell_time_active/repeat_probe_time)
= (28/11) = 2.

Change-Id: I8a3f3dbaf70c666973454e3266e0dabe0df1c9ea
CRs-Fixed: 992655
Liangwei Dong 8 years ago
parent
commit
271f92f582
2 changed files with 12 additions and 5 deletions
  1. 1 1
      core/wma/inc/wma.h
  2. 11 4
      core/wma/src/wma_scan_roam.c

+ 1 - 1
core/wma/inc/wma.h

@@ -493,7 +493,7 @@ typedef struct probeTime_dwellTime {
 
 static const t_probeTime_dwellTime
 	probe_time_dwell_time_map[WMA_DWELL_TIME_PROBE_TIME_MAP_SIZE] = {
-	{28, 0},                /* 0 SSID */
+	{28, 11},               /* 0 SSID */
 	{28, 20},               /* 1 SSID */
 	{28, 20},               /* 2 SSID */
 	{28, 20},               /* 3 SSID */

+ 11 - 4
core/wma/src/wma_scan_roam.c

@@ -233,10 +233,6 @@ QDF_STATUS wma_get_buf_start_scan_cmd(tp_wma_handle wma_handle,
 	} else
 		cmd->dwell_time_passive = scan_req->maxChannelTime;
 
-	WMA_LOGI("Scan Type %x, Active dwell time %u, Passive dwell time %u",
-		 scan_req->scanType, cmd->dwell_time_active,
-		 cmd->dwell_time_passive);
-
 	/* Ensure correct number of probes are sent on active channel */
 	cmd->repeat_probe_time =
 		cmd->dwell_time_active / WMA_SCAN_NPROBES_DEFAULT;
@@ -465,8 +461,19 @@ QDF_STATUS wma_get_buf_start_scan_cmd(tp_wma_handle wma_handle,
 				QDF_MIN(SSID_num,
 					WMA_DWELL_TIME_PROBE_TIME_MAP_SIZE
 					- 1)].probe_time;
+			cmd->n_probes = (cmd->repeat_probe_time > 0) ?
+				cmd->dwell_time_active/
+				cmd->repeat_probe_time : 0;
 		}
 	}
+	WMA_LOGI("Scan Type 0x%x, Active dwell time %u, Passive dwell time %u",
+		scan_req->scanType, cmd->dwell_time_active,
+		cmd->dwell_time_passive);
+	WMA_LOGI("Scan repeat_probe_time %u n_probes %u num_ssids %u num_bssid %u",
+		cmd->repeat_probe_time,
+		cmd->n_probes,
+		cmd->num_ssids,
+		cmd->num_bssid);
 
 	qdf_mem_copy(cmd->mac_add_bytes, scan_req->bssId.bytes, QDF_MAC_ADDR_SIZE);
 	cmd->ie_len = scan_req->uIEFieldLen;