From 23afef1e1597934e0536636551da0ac63e6a6920 Mon Sep 17 00:00:00 2001 From: gaurank kathpalia Date: Thu, 4 Apr 2019 12:39:59 +0530 Subject: [PATCH] qcacld-3.0: Update only positive nss values from BDF If the FW doesn't send the ext service ready event, and thus the host does not get the max chainmask that both the macs can support, the host still updates the ini with the minimum of the host, and FW config, which can lead to functional issues in connection, and scan. Fix is to honour the setting only if the FW sends a non zero positive chainmask for both macs. Change-Id: I2a321923a2f995cca20cef3980acb1bf41ca0db0 CRs-Fixed: 2429584 --- core/sme/src/common/sme_api.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c index fd9db782d143..5d24c03f5f11 100644 --- a/core/sme/src/common/sme_api.c +++ b/core/sme/src/common/sme_api.c @@ -4449,7 +4449,12 @@ sme_modify_nss_chains_tgt_cfg(mac_handle_t mac_handle, } max_supported_rx_nss = QDF_MIN(ini_rx_nss, max_supported_rx_nss); + if (!max_supported_rx_nss) + return; + max_supported_tx_nss = QDF_MIN(ini_tx_nss, max_supported_tx_nss); + if (!max_supported_tx_nss) + return; ini_rx_chains = GET_VDEV_NSS_CHAIN(nss_chains_ini_cfg-> num_rx_chains[band], @@ -4468,8 +4473,13 @@ sme_modify_nss_chains_tgt_cfg(mac_handle_t mac_handle, max_supported_rx_chains = QDF_MIN(ini_rx_chains, max_supported_rx_chains); + if (!max_supported_rx_chains) + return; + max_supported_tx_chains = QDF_MIN(ini_tx_chains, max_supported_tx_chains); + if (!max_supported_tx_chains) + return; sme_modify_chains_in_mlme_cfg(mac_handle, max_supported_rx_chains, max_supported_tx_chains, vdev_op_mode,