summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRajeev Kumar Sirasanagandla <rsirasan@codeaurora.org>2016-12-15 11:34:43 +0530
committerGerrit - the friendly Code Review server <code-review@localhost>2016-12-15 05:47:36 -0800
commit27a0d5c4150bf73f9ddebfbc891884ffbbe1e7f9 (patch)
tree78f5074b4656c79f9a10542d8cd426f589cab3de
parent350d005440e21af495f6b3a528881f8a2cd5f184 (diff)
qcacld-2.0: Disable ie whitelisting in connected state
In the current implementation, probe req ie whitelisting feature is also enabled in connected state due to which, probe reqs in corresponding state are including selective IEs only. To avoid this, disable IE whitelisting feature in connected state. Change-Id: I52c78d40e8b97d89ff7cf63ef0bd6025e019a0db CRs-Fixed: 1101697
-rw-r--r--CORE/HDD/src/wlan_hdd_cfg80211.c41
1 files changed, 25 insertions, 16 deletions
diff --git a/CORE/HDD/src/wlan_hdd_cfg80211.c b/CORE/HDD/src/wlan_hdd_cfg80211.c
index 8b7dd0fc8167..6e9d4897c2a0 100644
--- a/CORE/HDD/src/wlan_hdd_cfg80211.c
+++ b/CORE/HDD/src/wlan_hdd_cfg80211.c
@@ -19905,6 +19905,7 @@ int __wlan_hdd_cfg80211_scan( struct wiphy *wiphy,
hdd_adapter_t *pAdapter = WLAN_HDD_GET_PRIV_PTR( dev );
hdd_context_t *pHddCtx = WLAN_HDD_GET_CTX( pAdapter );
hdd_wext_state_t *pwextBuf = WLAN_HDD_GET_WEXT_STATE_PTR(pAdapter);
+ hdd_station_ctx_t *station_ctx = WLAN_HDD_GET_STATION_CTX_PTR(pAdapter);
hdd_config_t *cfg_param = NULL;
tCsrScanRequest scanRequest;
tANI_U8 *channelList = NULL, i;
@@ -20285,24 +20286,26 @@ int __wlan_hdd_cfg80211_scan( struct wiphy *wiphy,
wlan_hdd_update_scan_rand_attrs((void *)&scanRequest, (void *)request,
WLAN_HDD_HOST_SCAN);
- if (pHddCtx->no_of_probe_req_ouis != 0) {
- scanRequest.voui = (struct vendor_oui *)vos_mem_malloc(
+ if (!hdd_connIsConnected(station_ctx)) {
+ if (pHddCtx->no_of_probe_req_ouis != 0) {
+ scanRequest.voui = (struct vendor_oui *)vos_mem_malloc(
pHddCtx->no_of_probe_req_ouis *
sizeof(struct vendor_oui));
- if (!scanRequest.voui) {
- hddLog(LOGE, FL("Not enough memory for voui"));
- scanRequest.num_vendor_oui = 0;
- status = -ENOMEM;
- goto free_mem;
+ if (!scanRequest.voui) {
+ hddLog(LOGE, FL("Not enough memory for voui"));
+ scanRequest.num_vendor_oui = 0;
+ status = -ENOMEM;
+ goto free_mem;
+ }
}
- }
- if (pHddCtx->cfg_ini->probe_req_ie_whitelist)
- wlan_hdd_fill_whitelist_ie_attrs(&scanRequest.ie_whitelist,
- scanRequest.probe_req_ie_bitmap,
- &scanRequest.num_vendor_oui,
- scanRequest.voui,
- pHddCtx);
+ if (pHddCtx->cfg_ini->probe_req_ie_whitelist)
+ wlan_hdd_fill_whitelist_ie_attrs(&scanRequest.ie_whitelist,
+ scanRequest.probe_req_ie_bitmap,
+ &scanRequest.num_vendor_oui,
+ scanRequest.voui,
+ pHddCtx);
+ }
vos_runtime_pm_prevent_suspend(pHddCtx->runtime_context.scan);
status = sme_ScanRequest( WLAN_HDD_GET_HAL_CTX(pAdapter),
@@ -24312,6 +24315,7 @@ static int __wlan_hdd_cfg80211_sched_scan_start(struct wiphy *wiphy,
hdd_scaninfo_t *pScanInfo = &pAdapter->scan_info;
hdd_config_t *config = NULL;
v_U32_t num_ignore_dfs_ch = 0;
+ hdd_station_ctx_t *station_ctx = WLAN_HDD_GET_STATION_CTX_PTR(pAdapter);
ENTER();
@@ -24373,9 +24377,13 @@ static int __wlan_hdd_cfg80211_sched_scan_start(struct wiphy *wiphy,
return -ENOTSUPP;
}
- pPnoRequest = (tpSirPNOScanReq) vos_mem_malloc(sizeof(tSirPNOScanReq) +
+ if (!hdd_connIsConnected(station_ctx))
+ pPnoRequest = (tpSirPNOScanReq) vos_mem_malloc(sizeof(tSirPNOScanReq) +
(pHddCtx->no_of_probe_req_ouis) *
(sizeof(struct vendor_oui)));
+ else
+ pPnoRequest = (tpSirPNOScanReq) vos_mem_malloc(sizeof(tSirPNOScanReq));
+
if (NULL == pPnoRequest)
{
VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_FATAL,
@@ -24543,7 +24551,8 @@ static int __wlan_hdd_cfg80211_sched_scan_start(struct wiphy *wiphy,
wlan_hdd_update_scan_rand_attrs((void *)pPnoRequest, (void *)request,
WLAN_HDD_PNO_SCAN);
- if (pHddCtx->cfg_ini->probe_req_ie_whitelist)
+ if (pHddCtx->cfg_ini->probe_req_ie_whitelist &&
+ !hdd_connIsConnected(station_ctx))
wlan_hdd_fill_whitelist_ie_attrs(&pPnoRequest->ie_whitelist,
pPnoRequest->probe_req_ie_bitmap,
&pPnoRequest->num_vendor_oui,