diff options
| author | Padma, Santhosh Kumar <skpadma@codeaurora.org> | 2016-11-02 18:23:36 +0530 |
|---|---|---|
| committer | Anjaneedevi Kapparapu <akappa@codeaurora.org> | 2016-11-11 19:44:04 +0530 |
| commit | dea8b6c6f53e5e262a0d2c127021c5dd44b4fc1b (patch) | |
| tree | f8f5072a3d7827e8436869c38e5b396b6fa2f045 | |
| parent | f28f31e407975b9878ba136dec8d90dacb7cd69f (diff) | |
qcacld-2.0: Update ext full scan results to kernel
Currently ext scan results are not updated to kernel. Update them
to kernel which can help kernel to have same scan results as
framework.
Change-Id: I3f1e7e9a67bfb6a984487b10020ae5a840fb6f78
CRs-Fixed: 1085001
| -rw-r--r-- | CORE/MAC/inc/sirApi.h | 2 | ||||
| -rw-r--r-- | CORE/MAC/src/pe/lim/limProcessMessageQueue.c | 7 | ||||
| -rw-r--r-- | CORE/SME/src/sme_common/sme_Api.c | 17 |
3 files changed, 23 insertions, 3 deletions
diff --git a/CORE/MAC/inc/sirApi.h b/CORE/MAC/inc/sirApi.h index 684cfe942016..6c4d8c1eab0f 100644 --- a/CORE/MAC/inc/sirApi.h +++ b/CORE/MAC/inc/sirApi.h @@ -5401,6 +5401,7 @@ struct extscan_cached_scan_results * @moreData: 0 - for last fragment * 1 - still more fragment(s) coming * @ap: bssid info + * @bss_description: BSS description * * Reported when each probe response is received, if reportEvents * enabled in tSirWifiScanCmdReqParams @@ -5410,6 +5411,7 @@ typedef struct uint32_t requestId; bool moreData; tSirWifiScanResult ap; + tSirBssDescription bss_description; } tSirWifiFullScanResultEvent, *tpSirWifiFullScanResultEvent; /** diff --git a/CORE/MAC/src/pe/lim/limProcessMessageQueue.c b/CORE/MAC/src/pe/lim/limProcessMessageQueue.c index 96607159c6db..34a869430cb4 100644 --- a/CORE/MAC/src/pe/lim/limProcessMessageQueue.c +++ b/CORE/MAC/src/pe/lim/limProcessMessageQueue.c @@ -244,14 +244,14 @@ __limExtScanForwardBcnProbeRsp(tpAniSirGlobal pmac, uint8_t *rx_pkt_info, tSirMsgQ mmh_msg; tpSirMacMgmtHdr hdr; - result = vos_mem_malloc(sizeof(*result) + ie_len); + result = vos_mem_malloc(sizeof(*result) + ie_len + ie_len); if (NULL == result) { limLog(pmac, LOGE, FL("Memory allocation failed")); return; } hdr = WDA_GET_RX_MAC_HEADER(rx_pkt_info); body = WDA_GET_RX_MPDU_DATA(rx_pkt_info); - vos_mem_zero(result, sizeof(*result) + ie_len); + vos_mem_zero(result, sizeof(*result) + ie_len + ie_len); /* Received frame does not have request id, hence set 0 */ result->requestId = 0; @@ -275,6 +275,9 @@ __limExtScanForwardBcnProbeRsp(tpAniSirGlobal pmac, uint8_t *rx_pkt_info, vos_mem_copy((uint8_t *) &result->ap.ieData, body + SIR_MAC_B_PR_SSID_OFFSET, ie_len); + limCollectBssDescription(pmac, &result->bss_description, + frame, rx_pkt_info, eANI_BOOLEAN_FALSE); + mmh_msg.type = msg_type; mmh_msg.bodyptr = result; mmh_msg.bodyval = 0; diff --git a/CORE/SME/src/sme_common/sme_Api.c b/CORE/SME/src/sme_common/sme_Api.c index 643d884b9700..a5d08da5796c 100644 --- a/CORE/SME/src/sme_common/sme_Api.c +++ b/CORE/SME/src/sme_common/sme_Api.c @@ -3269,7 +3269,21 @@ eHalStatus sme_ProcessMsg(tHalHandle hHal, vos_msg_t* pMsg) #ifdef FEATURE_WLAN_EXTSCAN case eWNI_SME_EXTSCAN_FULL_SCAN_RESULT_IND: { - if (pMac->sme.pExtScanIndCb) { + tCsrRoamInfo *roam_info; + tpSirWifiFullScanResultEvent result = + (tpSirWifiFullScanResultEvent) pMsg->bodyptr; + + roam_info = vos_mem_malloc(sizeof(*roam_info)); + if (roam_info) { + vos_mem_zero(roam_info, sizeof(*roam_info)); + roam_info->pBssDesc = &result->bss_description; + csrRoamCallCallback(pMac, 0, roam_info, 0, + eCSR_ROAM_UPDATE_SCAN_RESULT, eCSR_ROAM_RESULT_NONE); + vos_mem_free(roam_info); + } else + smsLog( pMac, LOGE, FL("vos_mem_malloc failed:")); + + if (pMac->sme.pExtScanIndCb) { pMac->sme.pExtScanIndCb(pMac->hHdd, eSIR_EXTSCAN_FULL_SCAN_RESULT_IND, pMsg->bodyptr); @@ -3277,6 +3291,7 @@ eHalStatus sme_ProcessMsg(tHalHandle hHal, vos_msg_t* pMsg) smsLog(pMac, LOGE, FL("callback not registered to process eWNI_SME_EXTSCAN_FULL_SCAN_RESULT_IND")); } + vos_mem_free(pMsg->bodyptr); break; } |
