diff options
| author | Ganesh Kondabattini <ganeshk@codeaurora.org> | 2016-05-30 15:29:03 +0530 |
|---|---|---|
| committer | qcabuildsw <qcabuildsw@localhost> | 2016-09-06 18:23:49 -0700 |
| commit | 53e873e85fdc5819c5431b384bb353bfe92038ff (patch) | |
| tree | 0260219abb58801a4f14980ab3977da14da508e3 | |
| parent | 6319f063aae801441626412eb4b6a5902f0fe8b8 (diff) | |
qcacld-3.0: Update the scan list with correct APs
qcacld-2.0 to qcacld-3.0 propagation
In the current implementation, DUT doesn't initialize the social
channels 1, 6 and 11 and doesn't support P2P discovery in 5GHz only
mode. So we don't see any AP's on 1, 6 and 11 channels during p2p scan.
Change-Id: I317119bbbc30d44214c11076faceba8101cf835a
CRs-Fixed: 962252
| -rw-r--r-- | core/mac/src/pe/lim/lim_process_beacon_frame.c | 25 | ||||
| -rw-r--r-- | core/mac/src/pe/lim/lim_scan_result_utils.c | 14 | ||||
| -rw-r--r-- | core/mac/src/pe/lim/lim_scan_result_utils.h | 2 |
3 files changed, 23 insertions, 18 deletions
diff --git a/core/mac/src/pe/lim/lim_process_beacon_frame.c b/core/mac/src/pe/lim/lim_process_beacon_frame.c index 74220499024e..b7546b257ed5 100644 --- a/core/mac/src/pe/lim/lim_process_beacon_frame.c +++ b/core/mac/src/pe/lim/lim_process_beacon_frame.c @@ -143,11 +143,16 @@ lim_process_beacon_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, eLIM_MLM_WT_PROBE_RESP_STATE) || (mac_ctx->lim.gLimMlmState == eLIM_MLM_PASSIVE_SCAN_STATE)) { - lim_check_and_add_bss_description(mac_ctx, bcn_ptr, - rx_pkt_info, - ((mac_ctx->lim.gLimHalScanState == - eLIM_HAL_SCANNING_STATE) ? true : false), - false); + /* If we are scanning for P2P, only accept probe rsp */ + if ((mac_ctx->lim.gLimHalScanState != + eLIM_HAL_SCANNING_STATE) || + (NULL == mac_ctx->lim.gpLimMlmScanReq) || + !mac_ctx->lim.gpLimMlmScanReq->p2pSearch) + lim_check_and_add_bss_description(mac_ctx, bcn_ptr, + rx_pkt_info, + ((mac_ctx->lim.gLimHalScanState == + eLIM_HAL_SCANNING_STATE) ? true : false), + false); /* * Calling dfsChannelList which will convert DFS channel * to active channel for x secs if this channel is DFS @@ -237,9 +242,13 @@ lim_process_beacon_frame_no_session(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo) if ((pMac->lim.gLimMlmState == eLIM_MLM_WT_PROBE_RESP_STATE) || (pMac->lim.gLimMlmState == eLIM_MLM_PASSIVE_SCAN_STATE)) { - lim_check_and_add_bss_description(pMac, pBeacon, - pRxPacketInfo, true, - false); + /*If we are scanning for P2P, only accept probe rsp */ + if ((pMac->lim.gLimHalScanState != + eLIM_HAL_SCANNING_STATE) || + (NULL == pMac->lim.gpLimMlmScanReq) || + !pMac->lim.gpLimMlmScanReq->p2pSearch) + lim_check_and_add_bss_description(pMac, pBeacon, + pRxPacketInfo, true, false); /* Calling dfsChannelList which will convert DFS channel * to Active channel for x secs if this channel is DFS channel */ lim_set_dfs_channel_list(pMac, pBeacon->channelNumber, diff --git a/core/mac/src/pe/lim/lim_scan_result_utils.c b/core/mac/src/pe/lim/lim_scan_result_utils.c index 65796e0f270e..dc65b8dfb2c8 100644 --- a/core/mac/src/pe/lim/lim_scan_result_utils.c +++ b/core/mac/src/pe/lim/lim_scan_result_utils.c @@ -70,7 +70,7 @@ * * @return None */ -QDF_STATUS +void lim_collect_bss_description(tpAniSirGlobal pMac, tSirBssDescription *pBssDescr, tpSirProbeRespBeacon pBPR, @@ -88,7 +88,7 @@ lim_collect_bss_description(tpAniSirGlobal pMac, if (SIR_MAC_B_PR_SSID_OFFSET > WMA_GET_RX_PAYLOAD_LEN(pRxPacketInfo)) { QDF_ASSERT(WMA_GET_RX_PAYLOAD_LEN(pRxPacketInfo) >= SIR_MAC_B_PR_SSID_OFFSET); - return QDF_STATUS_E_FAILURE; + return; } ieLen = WMA_GET_RX_PAYLOAD_LEN(pRxPacketInfo) - SIR_MAC_B_PR_SSID_OFFSET; @@ -229,7 +229,7 @@ lim_collect_bss_description(tpAniSirGlobal pMac, FL("Collected BSS Description for Channel(%1d), length(%u), IE Fields(%u)"), pBssDescr->channelId, pBssDescr->length, ieLen); - return QDF_STATUS_SUCCESS; + return; } /*** end lim_collect_bss_description() ***/ /** @@ -389,10 +389,8 @@ lim_check_and_add_bss_description(tpAniSirGlobal mac_ctx, return; } /* In scan state, store scan result. */ - status = lim_collect_bss_description(mac_ctx, bssdescr, - bpr, rx_packet_info, scanning); - if (QDF_STATUS_SUCCESS != status) - goto last; + lim_collect_bss_description(mac_ctx, bssdescr, bpr, rx_packet_info, + scanning); bssdescr->fProbeRsp = fProbeRsp; /* @@ -406,8 +404,6 @@ lim_check_and_add_bss_description(tpAniSirGlobal mac_ctx, FL("No CSR callback routine to send beacons")); status = QDF_STATUS_E_INVAL; } -last: qdf_mem_free(bssdescr); - return; } diff --git a/core/mac/src/pe/lim/lim_scan_result_utils.h b/core/mac/src/pe/lim/lim_scan_result_utils.h index 4548d28e7815..0b55f1741d97 100644 --- a/core/mac/src/pe/lim/lim_scan_result_utils.h +++ b/core/mac/src/pe/lim/lim_scan_result_utils.h @@ -46,7 +46,7 @@ void lim_restore_pre_scan_state(tpAniSirGlobal); void lim_copy_scan_result(tpAniSirGlobal, uint8_t *); void lim_check_and_add_bss_description(tpAniSirGlobal, tpSirProbeRespBeacon, uint8_t *, bool, uint8_t); -QDF_STATUS lim_collect_bss_description(tpAniSirGlobal pMac, +void lim_collect_bss_description(tpAniSirGlobal pMac, tSirBssDescription *pBssDescr, tpSirProbeRespBeacon pBPR, uint8_t *pRxPacketInfo, uint8_t fScanning); |
