qcacmn: Disable 11be functionality when not supported by fw
Disable 11be functionality when not supported by fw Change-Id: Ifb90893e15c9bc74aac3aab75220a0d5c866dd59 CRs-Fixed: 3291962
Cette révision appartient à :

révisé par
Madan Koyyalamudi

Parent
bf2b82dec7
révision
7e71dbe627
@@ -1848,6 +1848,11 @@ static int cm_calculate_mlo_bss_score(struct wlan_objmgr_psoc *psoc,
|
||||
struct partner_link_info *link;
|
||||
struct wlan_objmgr_pdev *pdev;
|
||||
bool rssi_bad_zone;
|
||||
bool eht_capab;
|
||||
|
||||
wlan_psoc_mlme_get_11be_capab(psoc, &eht_capab);
|
||||
if (!eht_capab)
|
||||
return 0;
|
||||
|
||||
weight_config = &score_params->weight_config;
|
||||
freq_entry = entry->channel.chan_freq;
|
||||
|
@@ -35,6 +35,7 @@
|
||||
#include <wlan_utility.h>
|
||||
#include <wlan_mlo_mgr_sta.h>
|
||||
#include <wlan_objmgr_vdev_obj.h>
|
||||
#include "wlan_psoc_mlme_api.h"
|
||||
|
||||
static void
|
||||
cm_fill_failure_resp_from_cm_id(struct cnx_mgr *cm_ctx,
|
||||
@@ -460,10 +461,16 @@ static void cm_update_vdev_mlme_macaddr(struct cnx_mgr *cm_ctx,
|
||||
struct cm_connect_req *req)
|
||||
{
|
||||
struct qdf_mac_addr *mac;
|
||||
bool eht_capab;
|
||||
|
||||
if (wlan_vdev_mlme_get_opmode(cm_ctx->vdev) != QDF_STA_MODE)
|
||||
return;
|
||||
|
||||
wlan_psoc_mlme_get_11be_capab(wlan_vdev_get_psoc(cm_ctx->vdev),
|
||||
&eht_capab);
|
||||
if (!eht_capab)
|
||||
return;
|
||||
|
||||
if (req->cur_candidate->entry->ie_list.multi_link) {
|
||||
wlan_vdev_obj_lock(cm_ctx->vdev);
|
||||
/* Use link address for ML connection */
|
||||
@@ -572,8 +579,9 @@ static void cm_create_bss_peer(struct cnx_mgr *cm_ctx,
|
||||
{
|
||||
QDF_STATUS status;
|
||||
struct qdf_mac_addr *bssid;
|
||||
struct qdf_mac_addr *mld_mac;
|
||||
struct qdf_mac_addr *mld_mac = NULL;
|
||||
bool is_assoc_link = false;
|
||||
bool eht_capab;
|
||||
|
||||
if (!cm_ctx) {
|
||||
mlme_err("invalid cm_ctx");
|
||||
@@ -583,10 +591,16 @@ static void cm_create_bss_peer(struct cnx_mgr *cm_ctx,
|
||||
mlme_err("invalid req");
|
||||
return;
|
||||
}
|
||||
|
||||
wlan_psoc_mlme_get_11be_capab(wlan_vdev_get_psoc(cm_ctx->vdev),
|
||||
&eht_capab);
|
||||
if (eht_capab) {
|
||||
cm_set_vdev_link_id(cm_ctx, req);
|
||||
mld_mac = cm_get_bss_peer_mld_addr(req);
|
||||
is_assoc_link = cm_bss_peer_is_assoc_peer(req);
|
||||
}
|
||||
|
||||
bssid = &req->cur_candidate->entry->bssid;
|
||||
cm_set_vdev_link_id(cm_ctx, req);
|
||||
mld_mac = cm_get_bss_peer_mld_addr(req);
|
||||
is_assoc_link = cm_bss_peer_is_assoc_peer(req);
|
||||
status = mlme_cm_bss_peer_create_req(cm_ctx->vdev, bssid,
|
||||
mld_mac, is_assoc_link);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
|
@@ -1,5 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 2021, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
@@ -44,7 +45,33 @@
|
||||
PLATFORM_VALUE(false, false), \
|
||||
"To enable max channel switch IE")
|
||||
|
||||
/*
|
||||
* <ini>
|
||||
* mlme_11be_target_capab - Flag to check the target capability for 11be
|
||||
* @Min: false
|
||||
* @Max: true
|
||||
* @Default: false
|
||||
*
|
||||
* This flag helps in confirming whether 11be is supported by the target.
|
||||
*
|
||||
* Related: None
|
||||
*
|
||||
* Supported Feature: 11be
|
||||
*
|
||||
* Usage: Internal
|
||||
*
|
||||
* </ini>
|
||||
*/
|
||||
#define CFG_MLME_11BE_TARGET_CAPAB CFG_UINT( \
|
||||
"mlme_11be_target_capab",\
|
||||
0, \
|
||||
1, \
|
||||
1, \
|
||||
CFG_VALUE_OR_DEFAULT, \
|
||||
"11be is supported by target")
|
||||
|
||||
#define CFG_CMN_MLME_ALL \
|
||||
CFG(CFG_MLME_MAX_CHAN_SWITCH_IE_ENABLE)
|
||||
CFG(CFG_MLME_MAX_CHAN_SWITCH_IE_ENABLE) \
|
||||
CFG(CFG_MLME_11BE_TARGET_CAPAB)
|
||||
|
||||
#endif /* __CFG_CMN_MLME_H */
|
||||
|
@@ -1,5 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 2019-2020 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
@@ -88,4 +89,23 @@ QDF_STATUS mlme_psoc_open(struct wlan_objmgr_psoc *psoc);
|
||||
*/
|
||||
QDF_STATUS mlme_psoc_close(struct wlan_objmgr_psoc *psoc);
|
||||
|
||||
/**
|
||||
* wlan_psoc_mlme_get_11be_capab() - Get the 11be capability for target
|
||||
* @psoc: psoc handle
|
||||
* @val: pointer to the output variable
|
||||
*
|
||||
* return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_psoc_mlme_get_11be_capab(struct wlan_objmgr_psoc *psoc, bool *val);
|
||||
|
||||
/**
|
||||
* wlan_psoc_mlme_set_11be_capab() - Set the 11be capability for target
|
||||
* @psoc: psoc handle
|
||||
* @val: pointer to the output variable
|
||||
*
|
||||
* return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS
|
||||
wlan_psoc_mlme_set_11be_capab(struct wlan_objmgr_psoc *psoc, bool val);
|
||||
#endif
|
||||
|
49
umac/mlme/psoc_mgr/dispatcher/inc/wlan_psoc_mlme_ucfg_api.h
Fichier normal
49
umac/mlme/psoc_mgr/dispatcher/inc/wlan_psoc_mlme_ucfg_api.h
Fichier normal
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for
|
||||
* any purpose with or without fee is hereby granted, provided that the
|
||||
* above copyright notice and this permission notice appear in all
|
||||
* copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
|
||||
* WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
|
||||
* WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
|
||||
* AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
|
||||
* DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
|
||||
* PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
|
||||
* TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/**
|
||||
* DOC: wlan_psoc_mlme_ucfg_api.h
|
||||
* This file provides PSOC mlme ucfg apis.
|
||||
*/
|
||||
#ifndef _WLAN_PSOC_MLME_UCFG_API_H_
|
||||
#define _WLAN_PSOC_MLME_UCFG_API_H_
|
||||
|
||||
#include <wlan_objmgr_psoc_obj.h>
|
||||
|
||||
/**
|
||||
* ucfg_psoc_mlme_get_11be_capab() - Get the 11be capability for target
|
||||
* @psoc: psoc handle
|
||||
* @val: pointer to the output variable
|
||||
*
|
||||
* return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS
|
||||
ucfg_psoc_mlme_get_11be_capab(struct wlan_objmgr_psoc *psoc, bool *val);
|
||||
|
||||
/**
|
||||
* ucfg_psoc_mlme_set_11be_capab() - Set the 11be capability for target
|
||||
* @psoc: psoc handle
|
||||
* @val: pointer to the output variable
|
||||
*
|
||||
* return: QDF_STATUS
|
||||
*/
|
||||
QDF_STATUS
|
||||
ucfg_psoc_mlme_set_11be_capab(struct wlan_objmgr_psoc *psoc, bool val);
|
||||
|
||||
#endif /* _WLAN_PSOC_MLME_UCFG_API_H_ */
|
||||
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 2019-2021 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
@@ -28,6 +28,36 @@
|
||||
#include "wlan_vdev_mgr_tgt_if_rx_api.h"
|
||||
#include <qdf_platform.h>
|
||||
|
||||
QDF_STATUS
|
||||
wlan_psoc_mlme_get_11be_capab(struct wlan_objmgr_psoc *psoc, bool *val)
|
||||
{
|
||||
struct psoc_mlme_obj *psoc_mlme;
|
||||
|
||||
psoc_mlme = wlan_psoc_mlme_get_cmpt_obj(psoc);
|
||||
if (!psoc_mlme) {
|
||||
mlme_err("psoc_mlme is NULL");
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
*val = psoc_mlme->psoc_cfg.phy_config.eht_cap;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
wlan_psoc_mlme_set_11be_capab(struct wlan_objmgr_psoc *psoc, bool val)
|
||||
{
|
||||
struct psoc_mlme_obj *psoc_mlme;
|
||||
|
||||
psoc_mlme = wlan_psoc_mlme_get_cmpt_obj(psoc);
|
||||
if (!psoc_mlme) {
|
||||
mlme_err("psoc_mlme is NULL");
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
psoc_mlme->psoc_cfg.phy_config.eht_cap &= val;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
struct psoc_mlme_obj *wlan_psoc_mlme_get_cmpt_obj(struct wlan_objmgr_psoc *psoc)
|
||||
{
|
||||
struct psoc_mlme_obj *psoc_mlme;
|
||||
@@ -94,6 +124,8 @@ static void mlme_init_cfg(struct wlan_objmgr_psoc *psoc)
|
||||
wlan_cm_init_score_config(psoc, &mlme_psoc_obj->psoc_cfg.score_config);
|
||||
mlme_psoc_obj->psoc_cfg.phy_config.max_chan_switch_ie =
|
||||
cfg_get(psoc, CFG_MLME_MAX_CHAN_SWITCH_IE_ENABLE);
|
||||
mlme_psoc_obj->psoc_cfg.phy_config.eht_cap =
|
||||
cfg_default(CFG_MLME_11BE_TARGET_CAPAB);
|
||||
}
|
||||
|
||||
QDF_STATUS mlme_psoc_open(struct wlan_objmgr_psoc *psoc)
|
||||
|
34
umac/mlme/psoc_mgr/dispatcher/src/wlan_psoc_mlme_ucfg_api.c
Fichier normal
34
umac/mlme/psoc_mgr/dispatcher/src/wlan_psoc_mlme_ucfg_api.c
Fichier normal
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/**
|
||||
* DOC: wlan_psoc_mlme_ucfg_api.c
|
||||
* This file contains psoc mlme ucfg APIs
|
||||
*/
|
||||
#include <wlan_psoc_mlme_ucfg_api.h>
|
||||
#include <wlan_psoc_mlme_api.h>
|
||||
|
||||
QDF_STATUS
|
||||
ucfg_psoc_mlme_get_11be_capab(struct wlan_objmgr_psoc *psoc, bool *val)
|
||||
{
|
||||
return wlan_psoc_mlme_get_11be_capab(psoc, val);
|
||||
}
|
||||
|
||||
QDF_STATUS
|
||||
ucfg_psoc_mlme_set_11be_capab(struct wlan_objmgr_psoc *psoc, bool val)
|
||||
{
|
||||
return wlan_psoc_mlme_set_11be_capab(psoc, val);
|
||||
}
|
@@ -33,6 +33,7 @@
|
||||
#ifdef WLAN_FEATURE_11BE_MLO
|
||||
#include <wlan_utility.h>
|
||||
#endif
|
||||
#include "wlan_psoc_mlme_api.h"
|
||||
|
||||
#define MAX_IE_LEN 1024
|
||||
#define SHORT_SSID_LEN 4
|
||||
@@ -953,17 +954,35 @@ util_scan_parse_rnr_ie(struct scan_cache_entry *scan_entry,
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
#ifdef WLAN_FEATURE_11BE
|
||||
#ifdef WLAN_FEATURE_11BE_MLO
|
||||
static void util_scan_parse_ml_ie(struct scan_cache_entry *scan_params,
|
||||
struct extn_ie_header *extn_ie)
|
||||
{
|
||||
if (extn_ie->ie_extn_id == WLAN_EXTN_ELEMID_MULTI_LINK)
|
||||
scan_params->ie_list.multi_link = (uint8_t *)extn_ie;
|
||||
}
|
||||
#else
|
||||
static void util_scan_parse_ml_ie(struct scan_cache_entry *scan_params,
|
||||
struct extn_ie_header *extn_ie)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
static void util_scan_parse_eht_ie(struct scan_cache_entry *scan_params,
|
||||
struct extn_ie_header *extn_ie)
|
||||
{
|
||||
switch (extn_ie->ie_extn_id) {
|
||||
case WLAN_EXTN_ELEMID_MULTI_LINK:
|
||||
scan_params->ie_list.multi_link = (uint8_t *)extn_ie;
|
||||
case WLAN_EXTN_ELEMID_EHTCAP:
|
||||
scan_params->ie_list.ehtcap = (uint8_t *)extn_ie;
|
||||
break;
|
||||
case WLAN_EXTN_ELEMID_EHTOP:
|
||||
scan_params->ie_list.ehtop = (uint8_t *)extn_ie;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
util_scan_parse_ml_ie(scan_params, extn_ie);
|
||||
}
|
||||
#else
|
||||
static void util_scan_parse_eht_ie(struct scan_cache_entry *scan_params,
|
||||
@@ -973,10 +992,14 @@ static void util_scan_parse_eht_ie(struct scan_cache_entry *scan_params,
|
||||
#endif
|
||||
|
||||
static QDF_STATUS
|
||||
util_scan_parse_extn_ie(struct scan_cache_entry *scan_params,
|
||||
struct ie_header *ie)
|
||||
util_scan_parse_extn_ie(struct wlan_objmgr_psoc *psoc,
|
||||
struct scan_cache_entry *scan_params,
|
||||
struct ie_header *ie)
|
||||
{
|
||||
struct extn_ie_header *extn_ie = (struct extn_ie_header *) ie;
|
||||
bool eht_capab;
|
||||
|
||||
wlan_psoc_mlme_get_11be_capab(psoc, &eht_capab);
|
||||
|
||||
switch (extn_ie->ie_extn_id) {
|
||||
case WLAN_EXTN_ELEMID_MAX_CHAN_SWITCH_TIME:
|
||||
@@ -1010,18 +1033,11 @@ util_scan_parse_extn_ie(struct scan_cache_entry *scan_params,
|
||||
return QDF_STATUS_E_INVAL;
|
||||
scan_params->ie_list.hecap_6g = (uint8_t *)ie;
|
||||
break;
|
||||
#ifdef WLAN_FEATURE_11BE
|
||||
case WLAN_EXTN_ELEMID_EHTCAP:
|
||||
scan_params->ie_list.ehtcap = (uint8_t *)ie;
|
||||
break;
|
||||
case WLAN_EXTN_ELEMID_EHTOP:
|
||||
scan_params->ie_list.ehtop = (uint8_t *)ie;
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
break;
|
||||
}
|
||||
util_scan_parse_eht_ie(scan_params, extn_ie);
|
||||
if (eht_capab)
|
||||
util_scan_parse_eht_ie(scan_params, extn_ie);
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
@@ -1400,7 +1416,7 @@ util_scan_populate_bcn_ie_list(struct wlan_objmgr_pdev *pdev,
|
||||
scan_params->ie_list.rsnxe = (uint8_t *)ie;
|
||||
break;
|
||||
case WLAN_ELEMID_EXTN_ELEM:
|
||||
status = util_scan_parse_extn_ie(scan_params, ie);
|
||||
status = util_scan_parse_extn_ie(psoc, scan_params, ie);
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
goto err_status;
|
||||
break;
|
||||
|
Référencer dans un nouveau ticket
Bloquer un utilisateur