Quellcode durchsuchen

qcacld-3.0: Add MLME CFG items of RTT and PMF

Add CFG items of RTT and PMF as generic items based
on converged cfg component.

Change-Id: Ic95d1e7b052259149704d9faf65ebe5f51536fdf
CRs-Fixed: 2313281
Karthik Kantamneni vor 6 Jahren
Ursprung
Commit
24f71bcfbf

+ 28 - 0
components/mlme/core/src/wlan_mlme_main.c

@@ -117,6 +117,33 @@ static void mlme_init_chainmask_cfg(struct wlan_objmgr_psoc *psoc,
 		cfg_get(psoc, CFG_RX_CHAIN_MASK_5G);
 }
 
+#ifdef WLAN_FEATURE_11W
+static void mlme_init_pmf_cfg(struct wlan_objmgr_psoc *psoc,
+			      struct wlan_mlme_generic *gen)
+{
+	gen->pmf_sa_query_max_retries =
+		cfg_get(psoc, CFG_PMF_SA_QUERY_MAX_RETRIES);
+	gen->pmf_sa_query_retry_interval =
+		cfg_get(psoc, CFG_PMF_SA_QUERY_RETRY_INTERVAL);
+}
+#else
+static void mlme_init_pmf_cfg(struct wlan_objmgr_psoc *psoc,
+			      struct wlan_mlme_generic *gen)
+{
+	gen->pmf_sa_query_max_retries =
+		cfg_default(CFG_PMF_SA_QUERY_MAX_RETRIES);
+	gen->pmf_sa_query_retry_interval =
+		cfg_default(CFG_PMF_SA_QUERY_RETRY_INTERVAL);
+}
+#endif /*WLAN_FEATURE_11W*/
+
+static void mlme_init_generic_cfg(struct wlan_objmgr_psoc *psoc,
+				  struct wlan_mlme_generic *gen)
+{
+	gen->rtt3_enabled = cfg_default(CFG_RTT3_ENABLE);
+	mlme_init_pmf_cfg(psoc, gen);
+}
+
 static void mlme_init_ht_cap_in_cfg(struct wlan_objmgr_psoc *psoc,
 				    struct wlan_mlme_ht_caps *ht_caps)
 {
@@ -704,6 +731,7 @@ QDF_STATUS mlme_cfg_on_psoc_enable(struct wlan_objmgr_psoc *psoc)
 	}
 
 	mlme_cfg = &mlme_obj->cfg;
+	mlme_init_generic_cfg(psoc, &mlme_cfg->gen);
 	mlme_init_ht_cap_in_cfg(psoc, &mlme_cfg->ht_caps);
 	mlme_init_mbo_cfg(psoc, &mlme_cfg->mbo_cfg);
 	mlme_init_qos_cfg(psoc, &mlme_cfg->qos_mlme_params);

+ 2 - 0
components/mlme/dispatcher/inc/cfg_mlme.h

@@ -24,6 +24,7 @@
 #include "qdf_types.h"
 
 #include "cfg_mlme_chainmask.h"
+#include "cfg_mlme_generic.h"
 #include "cfg_mlme_ht_caps.h"
 #include "cfg_mlme_he_caps.h"
 #include "cfg_mlme_lfr.h"
@@ -41,6 +42,7 @@
 /* Please Maintain Alphabetic Order here */
 #define CFG_MLME_ALL \
 	CFG_CHAINMASK_ALL \
+	CFG_GENERIC_ALL \
 	CFG_HT_CAPS_ALL \
 	CFG_HE_CAPS_ALL \
 	CFG_LFR_ALL \

+ 85 - 0
components/mlme/dispatcher/inc/cfg_mlme_generic.h

@@ -0,0 +1,85 @@
+/*
+ * Copyright (c) 2012-2018 The Linux Foundation. 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: This file contains centralized definitions of converged configuration.
+ */
+
+#ifndef __CFG_MLME_GENERIC_H
+#define __CFG_MLME_GENERIC_H
+
+#ifdef WLAN_FEATURE_11W
+#define CFG_PMF_SA_QUERY_MAX_RETRIES_TYPE	CFG_INI_UINT
+#define CFG_PMF_SA_QUERY_RETRY_INTERVAL_TYPE	CFG_INI_UINT
+#else
+#define CFG_PMF_SA_QUERY_MAX_RETRIES_TYPE	CFG_UINT
+#define CFG_PMF_SA_QUERY_RETRY_INTERVAL_TYPE	CFG_UINT
+#endif /*WLAN_FEATURE_11W*/
+
+/*
+ * pmfSaQueryMaxRetries - Control PMF SA query retries for SAP
+ * @Min: 0
+ * @Max: 20
+ * @Default: 5
+ *
+ * This ini to set the number of PMF SA query retries for SAP
+ *
+ * Related: None.
+ *
+ * Supported Feature: PMF(11W)
+ *
+ */
+#define CFG_PMF_SA_QUERY_MAX_RETRIES CFG_PMF_SA_QUERY_MAX_RETRIES_TYPE( \
+		"pmfSaQueryMaxRetries", \
+		0, \
+		20, \
+		5, \
+		CFG_VALUE_OR_DEFAULT, \
+		"PMF SA query retries for SAP")
+/*
+ * pmfSaQueryRetryInterval - Control PMF SA query retry interval
+ * for SAP in ms
+ * @Min: 10
+ * @Max: 2000
+ * @Default: 200
+ *
+ * This ini to set the PMF SA query retry interval for SAP in ms
+ *
+ * Related: None.
+ *
+ * Supported Feature: PMF(11W)
+ *
+ */
+#define CFG_PMF_SA_QUERY_RETRY_INTERVAL CFG_PMF_SA_QUERY_RETRY_INTERVAL_TYPE( \
+		"pmfSaQueryRetryInterval", \
+		10, \
+		2000, \
+		200, \
+		CFG_VALUE_OR_DEFAULT, \
+		"PMF SA query retry interval for SAP")
+
+#define CFG_RTT3_ENABLE CFG_BOOL( \
+		"rtt3_enabled", \
+		1, \
+		"RTT3 enable/disable info")
+
+#define CFG_GENERIC_ALL \
+	CFG(CFG_PMF_SA_QUERY_MAX_RETRIES) \
+	CFG(CFG_PMF_SA_QUERY_RETRY_INTERVAL) \
+	CFG(CFG_RTT3_ENABLE)
+#endif /* __CFG_MLME_GENERIC_H */

+ 14 - 0
components/mlme/dispatcher/inc/wlan_mlme_public_struct.h

@@ -354,6 +354,19 @@ struct wlan_mlme_chainmask {
 	uint8_t rx_chain_mask_5g;
 };
 
+/* struct wlan_mlme_generic - Generic CFG config items
+ *
+ * @rtt3_enabled:  RTT3 enable or disable info
+ * @pmf_sa_query_max_retries: PMF query max retries for SAP
+ * @pmf_sa_query_retry_interval: PMF query retry interval for SAP
+ *
+ */
+struct wlan_mlme_generic {
+	bool rtt3_enabled;
+	uint8_t pmf_sa_query_max_retries;
+	uint16_t pmf_sa_query_retry_interval;
+};
+
 /**
  * struct wlan_mlme_obss_ht40 - OBSS HT40 config items
  * @active_dwelltime:        obss active dwelltime
@@ -647,6 +660,7 @@ struct wlan_mlme_oce {
  * @scoring: BSS Scoring related CFG Items
  */
 struct wlan_mlme_cfg {
+	struct wlan_mlme_generic gen;
 	struct wlan_mlme_ht_caps ht_caps;
 	struct wlan_mlme_he_caps he_caps;
 	struct wlan_mlme_lfr_cfg lfr;

+ 0 - 52
core/hdd/inc/wlan_hdd_cfg.h

@@ -6251,53 +6251,6 @@ enum hdd_link_speed_rpt_type {
 
 #endif /* MSM_PLATFORM */
 
-#ifdef WLAN_FEATURE_11W
-/*
- * <ini>
- * pmfSaQueryMaxRetries - Control PMF SA query retries for SAP
- * @Min: 0
- * @Max: 20
- * @Default: 5
- *
- * This ini to set the number of PMF SA query retries for SAP
- *
- * Related: None.
- *
- * Supported Feature: PMF(11W)
- *
- * Usage: Internal/External
- *
- * </ini>
- */
-#define CFG_PMF_SA_QUERY_MAX_RETRIES_NAME          "pmfSaQueryMaxRetries"
-#define CFG_PMF_SA_QUERY_MAX_RETRIES_DEFAULT       (5)
-#define CFG_PMF_SA_QUERY_MAX_RETRIES_MIN           (0)
-#define CFG_PMF_SA_QUERY_MAX_RETRIES_MAX           (20)
-
-/*
- * <ini>
- * pmfSaQueryRetryInterval - Control PMF SA query retry interval
- * for SAP in ms
- * @Min: 0
- * @Max: 2000
- * @Default: 200
- *
- * This ini to set the PMF SA query retry interval for SAP in ms
- *
- * Related: None.
- *
- * Supported Feature: PMF(11W)
- *
- * Usage: Internal/External
- *
- * </ini>
- */
-#define CFG_PMF_SA_QUERY_RETRY_INTERVAL_NAME       "pmfSaQueryRetryInterval"
-#define CFG_PMF_SA_QUERY_RETRY_INTERVAL_DEFAULT    (200)
-#define CFG_PMF_SA_QUERY_RETRY_INTERVAL_MIN        (0)
-#define CFG_PMF_SA_QUERY_RETRY_INTERVAL_MAX        (2000)
-#endif
-
 /*
  * <ini>
  * gMaxConcurrentActiveSessions - Maximum number of concurrent connections.
@@ -11193,11 +11146,6 @@ struct hdd_config {
 	/* RTS profile parameter */
 	uint32_t rts_profile;
 
-#ifdef WLAN_FEATURE_11W
-	uint32_t pmfSaQueryMaxRetries;
-	uint32_t pmfSaQueryRetryInterval;
-#endif
-
 	uint8_t gMaxConcurrentActiveSessions;
 
 	uint8_t ignoreCAC;

+ 0 - 31
core/hdd/src/wlan_hdd_cfg.c

@@ -2649,21 +2649,6 @@ struct reg_table_entry g_registry_table[] = {
 			    VAR_FLAGS_NONE,
 			    (void *)CFG_ENABLE_CONCURRENT_STA_DEFAULT),
 
-#ifdef WLAN_FEATURE_11W
-	REG_VARIABLE(CFG_PMF_SA_QUERY_MAX_RETRIES_NAME, WLAN_PARAM_Integer,
-		     struct hdd_config, pmfSaQueryMaxRetries,
-		     VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
-		     CFG_PMF_SA_QUERY_MAX_RETRIES_DEFAULT,
-		     CFG_PMF_SA_QUERY_MAX_RETRIES_MIN,
-		     CFG_PMF_SA_QUERY_MAX_RETRIES_MAX),
-
-	REG_VARIABLE(CFG_PMF_SA_QUERY_RETRY_INTERVAL_NAME, WLAN_PARAM_Integer,
-		     struct hdd_config, pmfSaQueryRetryInterval,
-		     VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
-		     CFG_PMF_SA_QUERY_RETRY_INTERVAL_DEFAULT,
-		     CFG_PMF_SA_QUERY_RETRY_INTERVAL_MIN,
-		     CFG_PMF_SA_QUERY_RETRY_INTERVAL_MAX),
-#endif
 	REG_VARIABLE(CFG_MAX_CONCURRENT_CONNECTIONS_NAME, WLAN_PARAM_Integer,
 		     struct hdd_config, gMaxConcurrentActiveSessions,
 		     VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
@@ -5791,22 +5776,6 @@ bool hdd_update_config_cfg(struct hdd_context *hdd_ctx)
 		hdd_err("Couldn't pass on WNI_CFG_DISABLE_LDPC_WITH_TXBF_AP to CFG");
 	}
 
-#ifdef WLAN_FEATURE_11W
-	if (sme_cfg_set_int(mac_handle, WNI_CFG_PMF_SA_QUERY_MAX_RETRIES,
-			    config->pmfSaQueryMaxRetries) ==
-			QDF_STATUS_E_FAILURE) {
-		status = false;
-		hdd_err("Couldn't pass on WNI_CFG_SA_QUERY_MAX_RETRIES to CFG");
-	}
-
-	if (sme_cfg_set_int(mac_handle, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
-			    config->pmfSaQueryRetryInterval) ==
-			QDF_STATUS_E_FAILURE) {
-		status = false;
-		hdd_err("Couldn't pass on WNI_CFG_SA_QUERY_RETRY_INTERVAL to CFG");
-	}
-#endif
-
 	if (sme_cfg_set_int(mac_handle, WNI_CFG_IBSS_ATIM_WIN_SIZE,
 			    config->ibssATIMWinSize) ==
 			QDF_STATUS_E_FAILURE) {

+ 0 - 15
core/mac/inc/wni_cfg.h

@@ -175,10 +175,7 @@ enum {
 	WNI_CFG_ENABLE_MCC_ADAPTIVE_SCHED,
 	WNI_CFG_DISABLE_LDPC_WITH_TXBF_AP,
 	WNI_CFG_AP_LINK_MONITOR_TIMEOUT,
-	WNI_CFG_PMF_SA_QUERY_MAX_RETRIES,
-	WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
 	WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY,
-	WNI_CFG_RTT3_ENABLE,
 	WNI_CFG_IBSS_ATIM_WIN_SIZE,
 	WNI_CFG_DFS_MASTER_ENABLED,
 	WNI_CFG_VHT_ENABLE_TXBF_20MHZ,
@@ -1078,22 +1075,10 @@ enum {
 #define WNI_CFG_AP_LINK_MONITOR_TIMEOUT_STAMAX    255
 #define WNI_CFG_AP_LINK_MONITOR_TIMEOUT_STADEF    3
 
-#define WNI_CFG_PMF_SA_QUERY_MAX_RETRIES_STAMIN    0
-#define WNI_CFG_PMF_SA_QUERY_MAX_RETRIES_STAMAX    20
-#define WNI_CFG_PMF_SA_QUERY_MAX_RETRIES_STADEF    5
-
-#define WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STAMIN    10
-#define WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STAMAX    2000
-#define WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STADEF    200
-
 #define WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY_STAMIN    100
 #define WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY_STAMAX    1000
 #define WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY_STADEF    300
 
-#define WNI_CFG_RTT3_ENABLE_STAMIN    0
-#define WNI_CFG_RTT3_ENABLE_STAMAX    1
-#define WNI_CFG_RTT3_ENABLE_STADEF    1
-
 #define WNI_CFG_IBSS_ATIM_WIN_SIZE_STAMIN    0
 #define WNI_CFG_IBSS_ATIM_WIN_SIZE_STAMAX    100
 #define WNI_CFG_IBSS_ATIM_WIN_SIZE_STADEF    0

+ 0 - 3
core/mac/src/cfg/cfg_param_name.c

@@ -189,10 +189,7 @@ const char *cfg_get_string(uint16_t cfg_id)
 	CASE_RETURN_STRING(WNI_CFG_ENABLE_MCC_ADAPTIVE_SCHED);
 	CASE_RETURN_STRING(WNI_CFG_DISABLE_LDPC_WITH_TXBF_AP);
 	CASE_RETURN_STRING(WNI_CFG_AP_LINK_MONITOR_TIMEOUT);
-	CASE_RETURN_STRING(WNI_CFG_PMF_SA_QUERY_MAX_RETRIES);
-	CASE_RETURN_STRING(WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL);
 	CASE_RETURN_STRING(WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY);
-	CASE_RETURN_STRING(WNI_CFG_RTT3_ENABLE);
 	CASE_RETURN_STRING(WNI_CFG_IBSS_ATIM_WIN_SIZE);
 	CASE_RETURN_STRING(WNI_CFG_DFS_MASTER_ENABLED);
 	CASE_RETURN_STRING(WNI_CFG_VHT_ENABLE_TXBF_20MHZ);

+ 0 - 17
core/mac/src/cfg/cfg_proc_msg.c

@@ -782,28 +782,11 @@ cgstatic cfg_static[CFG_PARAM_MAX_NUM] = {
 	WNI_CFG_AP_LINK_MONITOR_TIMEOUT_STAMIN,
 	WNI_CFG_AP_LINK_MONITOR_TIMEOUT_STAMAX,
 	WNI_CFG_AP_LINK_MONITOR_TIMEOUT_STADEF},
-	{WNI_CFG_PMF_SA_QUERY_MAX_RETRIES,
-	CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_INT |
-	CFG_CTL_RESTART,
-	WNI_CFG_PMF_SA_QUERY_MAX_RETRIES_STAMIN,
-	WNI_CFG_PMF_SA_QUERY_MAX_RETRIES_STAMAX,
-	WNI_CFG_PMF_SA_QUERY_MAX_RETRIES_STADEF},
-	{WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
-	CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_INT |
-	CFG_CTL_RESTART,
-	WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STAMIN,
-	WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STAMAX,
-	WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STADEF},
 	{WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY,
 	CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_INT,
 	WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY_STAMIN,
 	WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY_STAMAX,
 	WNI_CFG_RMC_ACTION_PERIOD_FREQUENCY_STADEF},
-	{WNI_CFG_RTT3_ENABLE,
-	CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_INT,
-	WNI_CFG_RTT3_ENABLE_STAMIN,
-	WNI_CFG_RTT3_ENABLE_STAMAX,
-	WNI_CFG_RTT3_ENABLE_STADEF},
 	{WNI_CFG_IBSS_ATIM_WIN_SIZE,
 	CFG_CTL_VALID | CFG_CTL_RE | CFG_CTL_WE | CFG_CTL_INT,
 	WNI_CFG_IBSS_ATIM_WIN_SIZE_STAMIN,

+ 5 - 12
core/mac/src/pe/lim/lim_process_assoc_req_frame.c

@@ -25,6 +25,7 @@
 #include "wni_cfg.h"
 #include "sir_api.h"
 #include "cfg_api.h"
+#include "cfg_ucfg_api.h"
 
 #include "sch_api.h"
 #include "utils_api.h"
@@ -1276,7 +1277,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
 	uint8_t *ht_cap_ie = NULL;
 #ifdef WLAN_FEATURE_11W
 	tPmfSaQueryTimerId timer_id;
-	uint32_t retry_interval;
+	uint16_t retry_interval;
 #endif
 	tDot11fIEVHTCaps *vht_caps;
 	tpSirAssocReq tmp_assoc_req;
@@ -1575,17 +1576,9 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
 	sta_ds->pmfSaQueryState = DPH_SA_QUERY_NOT_IN_PROGRESS;
 	timer_id.fields.sessionId = session->peSessionId;
 	timer_id.fields.peerIdx = peer_idx;
-	if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
-			&retry_interval) != QDF_STATUS_SUCCESS) {
-		pe_err("Couldn't get PMF SA Query retry interval value");
-		lim_reject_association(mac_ctx, hdr->sa, sub_type, true,
-			auth_type, peer_idx, false,
-			eSIR_MAC_UNSPEC_FAILURE_STATUS,
-			session);
-		return false;
-	}
-	if (WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STAMIN > retry_interval) {
-		retry_interval = WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL_STADEF;
+	retry_interval = mac_ctx->mlme_cfg->gen.pmf_sa_query_retry_interval;
+	if (cfg_min(CFG_PMF_SA_QUERY_RETRY_INTERVAL) > retry_interval) {
+		retry_interval = cfg_default(CFG_PMF_SA_QUERY_RETRY_INTERVAL);
 	}
 	if (sta_ds->rmfEnabled &&
 		tx_timer_create(mac_ctx, &sta_ds->pmfSaQueryTimer,

+ 10 - 16
core/mac/src/pe/lim/lim_send_management_frames.c

@@ -1119,8 +1119,8 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx,
 	tDot11fIEExtCap extracted_ext_cap;
 	bool extracted_flag = false;
 #ifdef WLAN_FEATURE_11W
-	uint32_t retry_int;
-	uint32_t max_retries;
+	uint8_t retry_int;
+	uint16_t max_retries;
 #endif
 
 	if (NULL == pe_session) {
@@ -1256,20 +1256,14 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx,
 		}
 #ifdef WLAN_FEATURE_11W
 		if (eSIR_MAC_TRY_AGAIN_LATER == status_code) {
-			if (wlan_cfg_get_int
-				    (mac_ctx, WNI_CFG_PMF_SA_QUERY_MAX_RETRIES,
-				    &max_retries) != QDF_STATUS_SUCCESS)
-				pe_err("get WNI_CFG_PMF_SA_QUERY_MAX_RETRIES failure");
-			else if (wlan_cfg_get_int
-					 (mac_ctx,
-					 WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
-					 &retry_int) != QDF_STATUS_SUCCESS)
-				pe_err("get WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL failure");
-			else
-				populate_dot11f_timeout_interval(mac_ctx,
-					&frm.TimeoutInterval,
-					SIR_MAC_TI_TYPE_ASSOC_COMEBACK,
-					(max_retries -
+			max_retries =
+			mac_ctx->mlme_cfg->gen.pmf_sa_query_max_retries;
+			retry_int =
+			mac_ctx->mlme_cfg->gen.pmf_sa_query_retry_interval;
+			populate_dot11f_timeout_interval(mac_ctx,
+							 &frm.TimeoutInterval,
+						SIR_MAC_TI_TYPE_ASSOC_COMEBACK,
+						(max_retries -
 						sta->pmfSaQueryRetryCount)
 						* retry_int);
 		}

+ 3 - 8
core/mac/src/pe/lim/lim_utils.c

@@ -5874,7 +5874,7 @@ void lim_pmf_sa_query_timer_handler(void *pMacGlobal, uint32_t param)
 	tPmfSaQueryTimerId timerId;
 	tpPESession psessionEntry;
 	tpDphHashNode pSta;
-	uint32_t maxRetries;
+	uint8_t maxretries;
 
 	pe_debug("SA Query timer fires");
 	timerId.value = param;
@@ -5898,14 +5898,9 @@ void lim_pmf_sa_query_timer_handler(void *pMacGlobal, uint32_t param)
 		return;
 
 	/* Increment the retry count, check if reached maximum */
-	if (wlan_cfg_get_int(pMac, WNI_CFG_PMF_SA_QUERY_MAX_RETRIES,
-			     &maxRetries) != QDF_STATUS_SUCCESS) {
-		pe_err("Could not retrieve PMF SA Query maximum retries value");
-		pSta->pmfSaQueryState = DPH_SA_QUERY_NOT_IN_PROGRESS;
-		return;
-	}
+	maxretries = pMac->mlme_cfg->gen.pmf_sa_query_max_retries;
 	pSta->pmfSaQueryRetryCount++;
-	if (pSta->pmfSaQueryRetryCount >= maxRetries) {
+	if (pSta->pmfSaQueryRetryCount >= maxretries) {
 		pe_err("SA Query timed out,Deleting STA");
 		lim_print_mac_addr(pMac, pSta->staAddr, LOGE);
 		lim_send_disassoc_mgmt_frame(pMac,

+ 1 - 8
core/mac/src/sys/legacy/src/utils/src/parser_api.c

@@ -1144,7 +1144,6 @@ populate_dot11f_ext_cap(tpAniSirGlobal pMac,
 			bool isVHTEnabled, tDot11fIEExtCap *pDot11f,
 			tpPESession psessionEntry)
 {
-	uint32_t val = 0;
 	struct s_ext_cap *p_ext_cap;
 
 	pDot11f->present = 1;
@@ -1169,13 +1168,7 @@ populate_dot11f_ext_cap(tpAniSirGlobal pMac,
 	if (isVHTEnabled == true)
 		p_ext_cap->oper_mode_notification = 1;
 
-	if (wlan_cfg_get_int(pMac, WNI_CFG_RTT3_ENABLE, &val) !=
-							QDF_STATUS_SUCCESS) {
-		pe_err("could not retrieve RTT3 Variable from DAT File");
-		return QDF_STATUS_E_FAILURE;
-	}
-
-	if (val) {
+	if (pMac->mlme_cfg->gen.rtt3_enabled) {
 		uint32_t ftm = ucfg_wifi_pos_get_ftm_cap(pMac->psoc);
 		if (!psessionEntry || LIM_IS_STA_ROLE(psessionEntry)) {
 			p_ext_cap->fine_time_meas_initiator =

+ 5 - 13
core/wma/src/wma_mgmt.c

@@ -830,7 +830,8 @@ void wma_set_sta_sa_query_param(tp_wma_handle wma,
 				  uint8_t vdev_id)
 {
 	struct sAniSirGlobal *mac = cds_get_context(QDF_MODULE_ID_PE);
-	uint32_t max_retries, retry_interval;
+	uint8_t max_retries;
+	uint16_t retry_interval;
 
 	WMA_LOGD(FL("Enter:"));
 
@@ -838,18 +839,9 @@ void wma_set_sta_sa_query_param(tp_wma_handle wma,
 		WMA_LOGE(FL("mac context is NULL"));
 		return;
 	}
-	if (wlan_cfg_get_int
-		    (mac, WNI_CFG_PMF_SA_QUERY_MAX_RETRIES,
-		    &max_retries) != QDF_STATUS_SUCCESS) {
-		max_retries = DEFAULT_STA_SA_QUERY_MAX_RETRIES_COUNT;
-		WMA_LOGE(FL("Failed to get value for WNI_CFG_PMF_SA_QUERY_MAX_RETRIES"));
-	}
-	if (wlan_cfg_get_int
-		    (mac, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
-		    &retry_interval) != QDF_STATUS_SUCCESS) {
-		retry_interval = DEFAULT_STA_SA_QUERY_RETRY_INTERVAL;
-		WMA_LOGE(FL("Failed to get value for WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL"));
-	}
+
+	max_retries = mac->mlme_cfg->gen.pmf_sa_query_max_retries;
+	retry_interval = mac->mlme_cfg->gen.pmf_sa_query_retry_interval;
 
 	wmi_unified_set_sta_sa_query_param_cmd(wma->wmi_handle,
 						vdev_id,