From 6a44405bb12df076908359f6b54f84503af5a107 Mon Sep 17 00:00:00 2001 From: Pragaspathi Thilagaraj Date: Tue, 16 Mar 2021 19:12:49 +0530 Subject: [PATCH] qcacld-3.0: Handle TWT teardown with new reason code Firmware sends TWT teardown with status code WMI_DEL_TWT_STATUS_CONCURRENT_SESSION when a concurrent connection is established. Currently host driver drops this event as the status code is not WMI_DEL_TWT_STATUS_ROAMING_INITIATED or WMI_DEL_TWT_STATUS_PEER_INITIATED. Add support to handle TWT teardown event with WMI_DEL_TWT_STATUS_CONCURRENT_SESSION status code. Change-Id: I408ba960924b4daa1ca4f8337d7e0d1ce52c5fd9 CRs-Fixed: 2899563 --- core/hdd/src/wlan_hdd_twt.c | 2 ++ core/sme/src/common/sme_api.c | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/core/hdd/src/wlan_hdd_twt.c b/core/hdd/src/wlan_hdd_twt.c index 4c7c4eac4dfc..95ae829575a7 100644 --- a/core/hdd/src/wlan_hdd_twt.c +++ b/core/hdd/src/wlan_hdd_twt.c @@ -1010,6 +1010,8 @@ int wmi_twt_del_status_to_vendor_twt_status(enum WMI_HOST_DEL_TWT_STATUS status) return QCA_WLAN_VENDOR_TWT_STATUS_PEER_INITIATED_TERMINATE; case WMI_HOST_DEL_TWT_STATUS_ROAMING: return QCA_WLAN_VENDOR_TWT_STATUS_ROAM_INITIATED_TERMINATE; + case WMI_HOST_DEL_TWT_STATUS_CONCURRENCY: + return QCA_WLAN_VENDOR_TWT_STATUS_SCC_MCC_CONCURRENCY_TERMINATE; default: return QCA_WLAN_VENDOR_TWT_STATUS_UNKNOWN_ERROR; } diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c index 031fde23ee96..2d0728f22ea3 100644 --- a/core/sme/src/common/sme_api.c +++ b/core/sme/src/common/sme_api.c @@ -2145,7 +2145,8 @@ sme_process_twt_del_dialog_event(struct mac_context *mac, if (!is_evt_allowed && param->dialog_id != WLAN_ALL_SESSIONS_DIALOG_ID && param->status != WMI_HOST_DEL_TWT_STATUS_ROAMING && - param->status != WMI_HOST_DEL_TWT_STATUS_PEER_INIT_TEARDOWN) { + param->status != WMI_HOST_DEL_TWT_STATUS_PEER_INIT_TEARDOWN && + param->status != WMI_HOST_DEL_TWT_STATUS_CONCURRENCY) { sme_debug("Del dialog event dropped for id:%d status:%d", param->dialog_id, param->status); return;