qcacmn: Add per VDEV dot11 mode in VDEV MLME proto struct
To check the allowed dot11 mode of the VDEV, add new member to struct vdev_mlme_proto hold this value. Change-Id: I5bfbff0ab3056013a997744b8e9ce0b4d0a3d43b CRs-Fixed: 3314403
This commit is contained in:

committed by
Madan Koyyalamudi

parent
238df32c0b
commit
f6a2b48634
@@ -471,7 +471,10 @@ static void cm_update_vdev_mlme_macaddr(struct cnx_mgr *cm_ctx,
|
||||
if (!eht_capab)
|
||||
return;
|
||||
|
||||
if (req->cur_candidate->entry->ie_list.multi_link_bv) {
|
||||
mac = (struct qdf_mac_addr *)wlan_vdev_mlme_get_mldaddr(cm_ctx->vdev);
|
||||
|
||||
if (req->cur_candidate->entry->ie_list.multi_link_bv &&
|
||||
!qdf_is_macaddr_zero(mac)) {
|
||||
wlan_vdev_obj_lock(cm_ctx->vdev);
|
||||
/* Use link address for ML connection */
|
||||
wlan_vdev_mlme_set_macaddr(cm_ctx->vdev,
|
||||
@@ -480,15 +483,14 @@ static void cm_update_vdev_mlme_macaddr(struct cnx_mgr *cm_ctx,
|
||||
wlan_vdev_mlme_set_mlo_vdev(cm_ctx->vdev);
|
||||
mlme_debug("set link address for ML connection");
|
||||
} else {
|
||||
wlan_vdev_obj_lock(cm_ctx->vdev);
|
||||
/* Use net_dev address for non-ML connection */
|
||||
mac = (struct qdf_mac_addr *)cm_ctx->vdev->vdev_mlme.mldaddr;
|
||||
if (!qdf_is_macaddr_zero(mac)) {
|
||||
wlan_vdev_obj_lock(cm_ctx->vdev);
|
||||
wlan_vdev_mlme_set_macaddr(cm_ctx->vdev, mac->bytes);
|
||||
wlan_vdev_obj_unlock(cm_ctx->vdev);
|
||||
mlme_debug(QDF_MAC_ADDR_FMT " for non-ML connection",
|
||||
QDF_MAC_ADDR_REF(mac->bytes));
|
||||
}
|
||||
wlan_vdev_obj_unlock(cm_ctx->vdev);
|
||||
|
||||
wlan_vdev_mlme_clear_mlo_vdev(cm_ctx->vdev);
|
||||
mlme_debug("clear MLO cap for non-ML connection");
|
||||
|
@@ -288,9 +288,26 @@ struct vdev_mlme_eht_ops_info {
|
||||
};
|
||||
#endif
|
||||
|
||||
/**
|
||||
* enum mlme_vdev_dot11_mode - Dot11 mode of the vdev
|
||||
* MLME_VDEV_DOT11_MODE_AUTO: vdev uses mlme_dot11_mode
|
||||
* MLME_VDEV_DOT11_MODE_11N: vdev supports 11N mode
|
||||
* MLME_VDEV_DOT11_MODE_11AC: vdev supports 11AC mode
|
||||
* MLME_VDEV_DOT11_MODE_11AX: vdev supports 11AX mode
|
||||
* MLME_VDEV_DOT11_MODE_11BE: vdev supports 11BE mode
|
||||
*/
|
||||
enum mlme_vdev_dot11_mode {
|
||||
MLME_VDEV_DOT11_MODE_AUTO,
|
||||
MLME_VDEV_DOT11_MODE_11N,
|
||||
MLME_VDEV_DOT11_MODE_11AC,
|
||||
MLME_VDEV_DOT11_MODE_11AX,
|
||||
MLME_VDEV_DOT11_MODE_11BE,
|
||||
};
|
||||
|
||||
/**
|
||||
* struct vdev_mlme_he_ops_info - vdev protocol structure holding information
|
||||
* that is used in frames
|
||||
* @vdev_dot11_mode: supported dot11 mode
|
||||
* @generic: generic protocol information
|
||||
* @ap: ap specific protocol information
|
||||
* @sta: sta specific protocol information
|
||||
@@ -302,6 +319,7 @@ struct vdev_mlme_eht_ops_info {
|
||||
* @bss_color: 11ax HE BSS Color information
|
||||
*/
|
||||
struct vdev_mlme_proto {
|
||||
enum mlme_vdev_dot11_mode vdev_dot11_mode;
|
||||
struct vdev_mlme_proto_generic generic;
|
||||
struct vdev_mlme_proto_ap ap;
|
||||
struct vdev_mlme_proto_sta sta;
|
||||
|
@@ -681,6 +681,10 @@ static bool scm_check_dot11mode(struct scan_cache_entry *db_entry,
|
||||
if (!util_scan_entry_hecap(db_entry))
|
||||
return false;
|
||||
break;
|
||||
case ALLOW_11BE_ONLY:
|
||||
if (!util_scan_entry_ehtcap(db_entry))
|
||||
return false;
|
||||
break;
|
||||
default:
|
||||
scm_debug("Invalid dot11mode filter passed %d",
|
||||
filter->dot11mode);
|
||||
|
@@ -672,12 +672,14 @@ typedef struct filter_arg *bss_filter_arg_t;
|
||||
* @ALLOW_11N_ONLY: allow only 11n AP
|
||||
* @ALLOW_11AC_ONLY: allow only 11ac AP
|
||||
* @ALLOW_11AX_ONLY: allow only 11ax AP
|
||||
* @ALLOW_11BE_ONLY: allow only 11be AP
|
||||
*/
|
||||
enum dot11_mode_filter {
|
||||
ALLOW_ALL,
|
||||
ALLOW_11N_ONLY,
|
||||
ALLOW_11AC_ONLY,
|
||||
ALLOW_11AX_ONLY,
|
||||
ALLOW_11BE_ONLY,
|
||||
};
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user