diff options
| author | gaolez <gaolez@codeaurora.org> | 2019-04-25 17:34:20 +0800 |
|---|---|---|
| committer | gaolez <gaolez@codeaurora.org> | 2019-05-29 18:13:48 +0800 |
| commit | 0c20a626d695c84877acc72d75c5c86927cb0afa (patch) | |
| tree | 467732ef120bafc309fa9b5d191e3a6e6667a353 | |
| parent | 3edc6bbc733034efcbc4e8ae9803392aed73432c (diff) | |
qcacld-2.0: Add BSS hidden check in CSA
If CSA happened in a hidden BSS, we need keep the hidden flag and
ssid info for the target channel, if not, the SAP will reply the
probe request for the broadcast SSID.
CRs-Fixed: 2441874
Change-Id: I30b17016d4dae4e7ec7d6782aff4654930b015b2
| -rw-r--r-- | CORE/MAC/src/pe/lim/limSendMessages.c | 13 | ||||
| -rw-r--r-- | CORE/SERVICES/WMA/wma.c | 40 | ||||
| -rw-r--r-- | CORE/WDA/inc/legacy/halMsgApi.h | 2 |
3 files changed, 38 insertions, 17 deletions
diff --git a/CORE/MAC/src/pe/lim/limSendMessages.c b/CORE/MAC/src/pe/lim/limSendMessages.c index c1dc90b20ea8..22094d95deed 100644 --- a/CORE/MAC/src/pe/lim/limSendMessages.c +++ b/CORE/MAC/src/pe/lim/limSendMessages.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2014, 2016, 2017, 2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2014, 2016-2019 The Linux Foundation. All rights reserved. * * Previously licensed under the ISC license by Qualcomm Atheros, Inc. * @@ -231,6 +231,17 @@ tSirRetStatus limSendSwitchChnlParams(tpAniSirGlobal pMac, limLog(pMac, LOG1, FL("Set sub20 channel width %d"), pSessionEntry->sub20_channelwidth); + if (pSessionEntry->ssidHidden) + pChnlParams->ssidHidden = pSessionEntry->ssidHidden; + + if (pSessionEntry->ssId.length) { + vos_mem_copy((uint8_t*)pChnlParams->ssid.ssId, + (uint8_t*)pSessionEntry->ssId.ssId, + pSessionEntry->ssId.length); + pChnlParams->ssid.length = pSessionEntry->ssId.length; + limLog(pMac, LOGE, FL("ssid name: %s length %d"), + pChnlParams->ssid.ssId, pChnlParams->ssid.length); + } //we need to defer the message until we get the response back from WDA. SET_LIM_PROCESS_DEFD_MESGS(pMac, false); msgQ.type = WDA_CHNL_SWITCH_REQ; diff --git a/CORE/SERVICES/WMA/wma.c b/CORE/SERVICES/WMA/wma.c index 5477ac7e3c70..e5b3741d0f72 100644 --- a/CORE/SERVICES/WMA/wma.c +++ b/CORE/SERVICES/WMA/wma.c @@ -15382,23 +15382,23 @@ VOS_STATUS wma_vdev_start(tp_wma_handle wma, cmd->beacon_interval = req->beacon_intval; cmd->dtim_period = req->dtim_period; - /* Copy the SSID */ - if (req->ssid.length) { - if (req->ssid.length < sizeof(cmd->ssid.ssid)) - cmd->ssid.ssid_len = req->ssid.length; - else - cmd->ssid.ssid_len = sizeof(cmd->ssid.ssid); - vos_mem_copy(cmd->ssid.ssid, req->ssid.ssId, - cmd->ssid.ssid_len); - } - - if (req->hidden_ssid) - cmd->flags |= WMI_UNIFIED_VDEV_START_HIDDEN_SSID; - if (req->pmf_enabled) cmd->flags |= WMI_UNIFIED_VDEV_START_PMF_ENABLED; } + if (req->hidden_ssid) + cmd->flags |= WMI_UNIFIED_VDEV_START_HIDDEN_SSID; + + /* Copy the SSID */ + if (req->ssid.length) { + if (req->ssid.length < sizeof(cmd->ssid.ssid)) + cmd->ssid.ssid_len = req->ssid.length; + else + cmd->ssid.ssid_len = sizeof(cmd->ssid.ssid); + vos_mem_copy(cmd->ssid.ssid, req->ssid.ssId, + cmd->ssid.ssid_len); + } + cmd->num_noa_descriptors = 0; buf_ptr = (u_int8_t *)(((uintptr_t) cmd) + sizeof(*cmd) + sizeof(wmi_channel)); @@ -15407,11 +15407,14 @@ VOS_STATUS wma_vdev_start(tp_wma_handle wma, sizeof(wmi_p2p_noa_descriptor)); WMA_LOGD("%s: vdev_id %d freq %d channel %d chanmode %d is_dfs %d " "beacon interval %d dtim %d center_chan %d center_freq2 %d " - "reg_info_1: 0x%x reg_info_2: 0x%x, req->max_txpow: 0x%x", + "reg_info_1: 0x%x reg_info_2: 0x%x, req->max_txpow: 0x%x" + "cmd flags 0x%x ssid len %d", __func__, req->vdev_id, chan->mhz, req->chan, chanmode, req->is_dfs, req->beacon_intval, cmd->dtim_period, chan->band_center_freq1, chan->band_center_freq2, chan->reg_info_1, chan->reg_info_2, - req->max_txpow); + req->max_txpow, cmd->flags, cmd->ssid.ssid_len); + + /* Store vdev params in SAP mode which can be used in vdev restart */ if (intr[req->vdev_id].type == WMI_VDEV_TYPE_AP && @@ -16103,7 +16106,12 @@ static void wma_set_channel(tp_wma_handle wma, tpSwitchChannelParams params) #endif req.beacon_intval = 100; req.dtim_period = 1; - req.is_dfs = params->isDfsChannel; + req.is_dfs = params->isDfsChannel; + req.hidden_ssid = params->ssidHidden; + req.ssid.length = params->ssid.length; + if (req.ssid.length > 0) + vos_mem_copy(req.ssid.ssId, params->ssid.ssId, + params->ssid.length); /* In case of AP mode, once radar is detected, we need to * issuse VDEV RESTART, so we making is_channel_switch as diff --git a/CORE/WDA/inc/legacy/halMsgApi.h b/CORE/WDA/inc/legacy/halMsgApi.h index 2fcc6b3325da..823033fe7a61 100644 --- a/CORE/WDA/inc/legacy/halMsgApi.h +++ b/CORE/WDA/inc/legacy/halMsgApi.h @@ -1007,6 +1007,8 @@ typedef struct * by way of ignoring if using new host/old FW or old host/new FW since it is at the end of this struct */ tSirMacAddr bssId; + uint8_t ssidHidden; + tSirMacSSid ssid; eHalStatus status; |
