Parcourir la source

qcacld-3.0: Fix TDLS ax throughput issue

When TDLS connection is made in 160 MHZ
for 11ax staions, the MCS rates for the
same aren't updated correctly.
Also, MCS rate can change in case the
connection between both stations is made
with AP operating in NSS 1x1, as there is
a check in lim_populate_he_mcs_set which
will disable MCS rates corresponding to
nss > 1x1.

To fix this, copy 160 MHZ mcs from the
staion parameters which gets updated in
change station. Also, use nss parameter
which is passed by lim_populate_he_mcs_set()
in the check which was used to disable mcs
rates corresponding to nss > 1x1. Thus,
peer station nss will be used to
determine whether to disable or not.

Change-Id: I23079aed3795202e6ae32583a220c1ed3227c1dd
CRs-Fixed: 2904540
Utkarsh Bhatnagar il y a 4 ans
Parent
commit
00b694406f

+ 6 - 2
components/tdls/dispatcher/inc/wlan_tdls_public_structs.h

@@ -774,8 +774,12 @@ struct hecap {
 	uint8_t mac_cap_info[6];
 	uint8_t phycap_info[11];
 	struct {
-		uint16_t rx_map;
-		uint16_t tx_map;
+		uint16_t rx_he_mcs_map_lt_80;
+		uint16_t tx_he_mcs_map_lt_80;
+		uint16_t rx_he_mcs_map_160;
+		uint16_t tx_he_mcs_map_160;
+		uint16_t rx_he_mcs_map_80_80;
+		uint16_t tx_he_mcs_map_80_80;
 	} he_cap_mcs_info;
 } qdf_packed;
 #endif

+ 1 - 1
core/mac/src/pe/lim/lim_utils.c

@@ -7621,7 +7621,7 @@ QDF_STATUS lim_populate_he_mcs_set(struct mac_context *mac_ctx,
 		(*(uint16_t *)peer_he_caps->rx_he_mcs_map_80_80),
 		(*(uint16_t *)peer_he_caps->tx_he_mcs_map_80_80));
 
-	if (session_entry->nss == NSS_2x2_MODE) {
+	if (nss == NSS_2x2_MODE) {
 		if (mac_ctx->mlme_cfg->gen.as_enabled &&
 		    wlan_reg_is_24ghz_ch_freq(session_entry->curr_op_freq)) {
 			if (IS_2X2_CHAIN(session_entry->chainMask))

+ 6 - 2
os_if/tdls/src/wlan_cfg80211_tdls.c

@@ -238,7 +238,8 @@ tdls_calc_channels_from_staparams(struct tdls_update_peer_params *req_info,
 }
 
 #ifdef WLAN_FEATURE_11AX
-#define MIN_TDLS_HE_CAP_LEN 21
+#define MIN_TDLS_HE_CAP_LEN 17
+#define MAX_TDLS_HE_CAP_LEN 29
 
 static void
 wlan_cfg80211_tdls_extract_he_params(struct tdls_update_peer_params *req_info,
@@ -256,8 +257,11 @@ wlan_cfg80211_tdls_extract_he_params(struct tdls_update_peer_params *req_info,
 	}
 
 	req_info->he_cap_len = params->he_capa_len;
+	if (req_info->he_cap_len > MAX_TDLS_HE_CAP_LEN)
+		req_info->he_cap_len = MAX_TDLS_HE_CAP_LEN;
+
 	qdf_mem_copy(&req_info->he_cap, params->he_capa,
-		     sizeof(struct hecap));
+		     req_info->he_cap_len);
 
 	return;
 }