From 8ed7afffc24b05daf1eef45b476253267818e1ec Mon Sep 17 00:00:00 2001 From: Abhinav Kumar Date: Wed, 24 Jul 2019 16:29:55 +0530 Subject: [PATCH] qcacld-3.0: Send BTM config and 11k offload for all roam reason Issue is : In case of STA + STA, Host sends BTM config enable on both STA. This results assert in FW as at a time FW supports BTM only on one vdev. Following are the fix: 1. Send 11k offload and BTM config enable to fw irrespective of roam reason. Enable of both while RSO start and disable of both while RSO stop should be symmetric. 2. Currently, Host sends RSO_UPDATE_CONFIG for blacklisting case if the vdev is in connected state irrespective of RSO start is sent or not. Added check to make sure RSO_UPDATE_CONFIG should not go if driver_disabled_roaming flag set. Change-Id: Ib92089906a2e1690ec6181ac184bc008ccfbc928 CRs-Fixed: 2497813 --- core/sme/src/csr/csr_api_roam.c | 6 +++--- core/wma/src/wma_scan_roam.c | 35 ++++++++++++++------------------- 2 files changed, 18 insertions(+), 23 deletions(-) diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index a997aac7c244..526f9607b501 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -19158,7 +19158,8 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id, return QDF_STATUS_E_FAILURE; } - if (command == ROAM_SCAN_OFFLOAD_START && + if ((command == ROAM_SCAN_OFFLOAD_START || + command == ROAM_SCAN_OFFLOAD_UPDATE_CFG) && (session->pCurRoamProfile && session->pCurRoamProfile->driver_disabled_roaming)) { if (reason == REASON_DRIVER_ENABLED) { @@ -19185,8 +19186,7 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id, sme_err("isRoamOffloadScanEnabled not set"); return QDF_STATUS_E_FAILURE; } - if (!csr_is_RSO_cmd_allowed(mac_ctx, command, session_id) && - reason != REASON_ROAM_SET_BLACKLIST_BSSID) { + if (!csr_is_RSO_cmd_allowed(mac_ctx, command, session_id)) { QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, ("RSO out-of-sync command %d lastSentCmd %d"), command, roam_info->last_sent_cmd); diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c index c6370a13e068..ed92a443865b 100644 --- a/core/wma/src/wma_scan_roam.c +++ b/core/wma/src/wma_scan_roam.c @@ -1784,33 +1784,28 @@ QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle, } /* Send BTM config as disabled during RSO Stop */ - if (roam_req->reason == REASON_CTX_INIT) { - qdf_status = wma_roam_scan_btm_offload(wma_handle, - roam_req); - if (QDF_IS_STATUS_ERROR(qdf_status)) { - WMA_LOGE("Sending BTM config to fw failed"); - break; - } + qdf_status = wma_roam_scan_btm_offload(wma_handle, + roam_req); + if (QDF_IS_STATUS_ERROR(qdf_status)) { + WMA_LOGE("Sending BTM config to fw failed"); + break; } /* * Send 11k offload enable and bss load trigger parameters * to FW as part of RSO Start */ - if (roam_req->reason == REASON_CTX_INIT) { - qdf_status = wma_send_offload_11k_params(wma_handle, - &roam_req->offload_11k_params); - if (qdf_status != QDF_STATUS_SUCCESS) { - WMA_LOGE("11k offload enable not sent, status %d", - qdf_status); - break; - } + qdf_status = wma_send_offload_11k_params(wma_handle, + &roam_req->offload_11k_params); + if (QDF_IS_STATUS_ERROR(qdf_status)) { + WMA_LOGE("11k offload enable not sent, status %d", + qdf_status); + break; + } - if (roam_req->bss_load_trig_enabled) { - bss_load_cfg = &roam_req->bss_load_config; - wma_send_roam_bss_load_config(wma_handle, - bss_load_cfg); - } + if (roam_req->bss_load_trig_enabled) { + bss_load_cfg = &roam_req->bss_load_config; + wma_send_roam_bss_load_config(wma_handle, bss_load_cfg); } wma_send_disconnect_roam_params(wma_handle, roam_req);