diff options
| author | gaolez <gaolez@codeaurora.org> | 2016-12-14 18:20:35 +0800 |
|---|---|---|
| committer | Ashish kumar goswami <agoswa@codeaurora.org> | 2017-01-05 16:12:43 +0530 |
| commit | ba2dd72d4713f3946325aa740bddf3c9e3dc72c7 (patch) | |
| tree | 895026ffdcce82c6aaa39c6236b9de8b01afdd69 | |
| parent | f270bb34c81289c9dcce470cf6b2e899dfc29670 (diff) | |
qcacld-2.0: Fix ACS report fix channel in 11a mode
Avoid select channel 0 when ACS select best channel from channel list.
Both acs channel list array and driver channel list array will have
empty element that channel num is 0, the ACS will compare two array to
select the best channel both in the acs channel list and driver channel
list, so it will select channel 0 and cause the ACS report fix channel
every time in 11a mode.
Change-Id: I3fe6571831be81116584056989c48eda21bc8f4c
CRs-Fixed: 1101613
| -rw-r--r-- | CORE/SAP/src/sapChSelect.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/CORE/SAP/src/sapChSelect.c b/CORE/SAP/src/sapChSelect.c index 5d8474053bc6..5d5ad165d50a 100644 --- a/CORE/SAP/src/sapChSelect.c +++ b/CORE/SAP/src/sapChSelect.c @@ -584,6 +584,8 @@ v_U8_t sapSelectPreferredChannelFromChannelList(v_U8_t bestChNum, for(count=0; count < pSpectInfoParams->numSpectChans ; count++) { bestChNum = (v_U8_t)pSpectInfoParams->pSpectCh[count].chNum; + if (bestChNum == 0) + continue; // Select the best channel from allowed list for(j=0;j < pSapCtx->acs_cfg->ch_list_count;j++) { @@ -2978,6 +2980,7 @@ v_U8_t sapSelectChannel(tHalHandle halHandle, ptSapContext pSapCtx, tScanResult { /* previous stored channel is better */ bestChNum = pSapCtx->acsBestChannelInfo.channelNum; + break; } else { |
