From cf1fa4c4600cdd8b34dc0ca3cd9eade05c56ba57 Mon Sep 17 00:00:00 2001 From: Sandeep Puligilla Date: Tue, 4 Jun 2019 01:45:06 -0700 Subject: [PATCH] qcacld-3.0: Fix RRM scan request dwell time Failed to set the RRM scan dwelltime below 40ms. Modified RRM scan request API to accept active dwelltime below 40ms and 110ms for passive scan. Change-Id: I0a1030c6c719950c08db0bc164623556b187fe9d CRs-Fixed: 2454281 --- core/sme/src/rrm/sme_rrm.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/core/sme/src/rrm/sme_rrm.c b/core/sme/src/rrm/sme_rrm.c index c9f513f8fef8..54b559818208 100644 --- a/core/sme/src/rrm/sme_rrm.c +++ b/core/sme/src/rrm/sme_rrm.c @@ -59,6 +59,8 @@ #ifdef FEATURE_WLAN_ESE #define RRM_ROAM_SCORE_NEIGHBOR_IAPP_LIST 30 #endif +/* RRM SCAN DWELL TIME */ +#define RRM_SCAN_MIN_DWELL_TIME 20 uint64_t rrm_scan_timer; @@ -841,13 +843,13 @@ static QDF_STATUS sme_rrm_issue_scan_req(struct mac_context *mac_ctx) * depending on type of scan. */ if (req->scan_req.scan_f_passive) { - if (max_chan_time > req->scan_req.dwell_time_passive) + if (max_chan_time >= RRM_SCAN_MIN_DWELL_TIME) req->scan_req.dwell_time_passive = max_chan_time; sme_debug("Passive Max Dwell Time(%d)", req->scan_req.dwell_time_passive); } else { - if (max_chan_time > req->scan_req.dwell_time_active) + if (max_chan_time >= RRM_SCAN_MIN_DWELL_TIME) req->scan_req.dwell_time_active = max_chan_time; sme_debug("Active Max Dwell Time(%d)", req->scan_req.dwell_time_active); @@ -1143,9 +1145,11 @@ QDF_STATUS sme_rrm_process_beacon_report_req_ind(struct mac_context *mac, (uint8_t *) &pBeaconReq->measurementDuration, SIR_ESE_MAX_MEAS_IE_REQS); - sme_debug("token: %d regClass: %d randnIntvl: %d msgSource: %d", + sme_debug("token: %d regClass: %d randnIntvl: %d msgSource: %d measurementduration %d, rrm_ctx duration %d", pSmeRrmContext->token, pSmeRrmContext->regClass, - pSmeRrmContext->randnIntvl, pSmeRrmContext->msgSource); + pSmeRrmContext->randnIntvl, pSmeRrmContext->msgSource, + pBeaconReq->measurementDuration[0], + pSmeRrmContext->duration[0]); return sme_rrm_issue_scan_req(mac);