From fbed5b3e5228ae9581524d6eec760e34dccfd546 Mon Sep 17 00:00:00 2001 From: Bapiraju Alla Date: Thu, 4 Feb 2021 15:51:39 +0530 Subject: [PATCH] qcacld-3.0: Reject pre CAC request when DBS is not supported Pre CAC feature requires parallel operation in 2.4GHz and 5GHz. So this feature won't be supported when there is no DBS support. Reject pre CAC request in this scanario. Change-Id: Iece04ac0f73aed2dfa1dd9bfd4869d96004534ce CRs-Fixed: 2870645 --- core/hdd/src/wlan_hdd_sap_cond_chan_switch.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/hdd/src/wlan_hdd_sap_cond_chan_switch.c b/core/hdd/src/wlan_hdd_sap_cond_chan_switch.c index 3c575f3285d9..8d6610596d71 100644 --- a/core/hdd/src/wlan_hdd_sap_cond_chan_switch.c +++ b/core/hdd/src/wlan_hdd_sap_cond_chan_switch.c @@ -181,6 +181,11 @@ static int __wlan_hdd_request_pre_cac(struct hdd_context *hdd_ctx, mac_handle_t mac_handle; bool val; + if (!policy_mgr_is_hw_dbs_capable(hdd_ctx->psoc)) { + hdd_debug("Pre CAC is not supported on non-dbs platforms"); + return -EINVAL; + } + pre_cac_adapter = hdd_get_adapter_by_iface_name(hdd_ctx, SAP_PRE_CAC_IFNAME); if (pre_cac_adapter) {