diff --git a/components/mlme/core/src/wlan_mlme_main.c b/components/mlme/core/src/wlan_mlme_main.c
index 86067bb6de..436ed80ddc 100644
--- a/components/mlme/core/src/wlan_mlme_main.c
+++ b/components/mlme/core/src/wlan_mlme_main.c
@@ -137,6 +137,33 @@ static void mlme_update_ht_cap_in_cfg(struct wlan_objmgr_psoc *psoc,
*ht_cap_info = u.default_ht_cap_info;
}
+static void mlme_init_qos_cfg(struct wlan_objmgr_psoc *psoc,
+ struct wlan_mlme_qos *qos_aggr_params)
+{
+ qos_aggr_params->tx_aggregation_size =
+ cfg_get(psoc, CFG_TX_AGGREGATION_SIZE);
+ qos_aggr_params->tx_aggregation_size_be =
+ cfg_get(psoc, CFG_TX_AGGREGATION_SIZEBE);
+ qos_aggr_params->tx_aggregation_size_bk =
+ cfg_get(psoc, CFG_TX_AGGREGATION_SIZEBK);
+ qos_aggr_params->tx_aggregation_size_vi =
+ cfg_get(psoc, CFG_TX_AGGREGATION_SIZEVI);
+ qos_aggr_params->tx_aggregation_size_vo =
+ cfg_get(psoc, CFG_TX_AGGREGATION_SIZEVO);
+ qos_aggr_params->rx_aggregation_size =
+ cfg_get(psoc, CFG_RX_AGGREGATION_SIZE);
+ qos_aggr_params->tx_aggr_sw_retry_threshold_be =
+ cfg_get(psoc, CFG_TX_AGGR_SW_RETRY_BE);
+ qos_aggr_params->tx_aggr_sw_retry_threshold_bk =
+ cfg_get(psoc, CFG_TX_AGGR_SW_RETRY_BK);
+ qos_aggr_params->tx_aggr_sw_retry_threshold_vi =
+ cfg_get(psoc, CFG_TX_AGGR_SW_RETRY_VI);
+ qos_aggr_params->tx_aggr_sw_retry_threshold_vo =
+ cfg_get(psoc, CFG_TX_AGGR_SW_RETRY_VO);
+ qos_aggr_params->sap_max_inactivity_override =
+ cfg_get(psoc, CFG_SAP_MAX_INACTIVITY_OVERRIDE);
+}
+
static void mlme_update_rates_in_cfg(struct wlan_objmgr_psoc *psoc,
struct wlan_mlme_rates *rates)
{
@@ -231,6 +258,7 @@ QDF_STATUS mlme_cfg_on_psoc_enable(struct wlan_objmgr_psoc *psoc)
mlme_cfg = &mlme_obj->cfg;
mlme_update_ht_cap_in_cfg(psoc, &mlme_cfg->ht_caps.ht_cap_info);
+ mlme_init_qos_cfg(psoc, &mlme_cfg->qos_mlme_params);
mlme_update_rates_in_cfg(psoc, &mlme_cfg->rates);
mlme_update_sap_protection_cfg(psoc, &mlme_cfg->sap_protection_cfg);
mlme_init_chainmask_cfg(psoc, &mlme_cfg->chainmask_cfg);
diff --git a/components/mlme/dispatcher/inc/cfg_mlme.h b/components/mlme/dispatcher/inc/cfg_mlme.h
index c3eb02ead4..81f7cc30e6 100644
--- a/components/mlme/dispatcher/inc/cfg_mlme.h
+++ b/components/mlme/dispatcher/inc/cfg_mlme.h
@@ -27,6 +27,7 @@
#include "cfg_mlme_ht_caps.h"
#include "cfg_mlme_obss_ht40.h"
#include "cfg_mlme_vht_caps.h"
+#include "cfg_qos.h"
#include "cfg_mlme_rates.h"
#include "cfg_sap_protection.h"
#include "cfg_mlme_sap.h"
@@ -36,6 +37,7 @@
CFG_HT_CAPS_ALL \
CFG_OBSS_HT40_ALL \
CFG_VHT_CAPS_ALL \
+ CFG_QOS_ALL \
CFG_RATES_ALL \
CFG_SAP_PROTECTION_ALL \
CFG_SAP_ALL
diff --git a/components/mlme/dispatcher/inc/cfg_qos.h b/components/mlme/dispatcher/inc/cfg_qos.h
new file mode 100644
index 0000000000..26d909ba3f
--- /dev/null
+++ b/components/mlme/dispatcher/inc/cfg_qos.h
@@ -0,0 +1,337 @@
+/*
+ * 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 QOS related
+ * converged configurations.
+ */
+
+#ifndef __CFG_MLME_QOS_H
+#define __CFG_MLME_QOS_H
+
+/*
+ *
+ * gTxAggregationSize - Gives an option to configure Tx aggregation size
+ * in no of MPDUs
+ * @Min: 0
+ * @Max: 64
+ * @Default: 64
+ *
+ * gTxAggregationSize gives an option to configure Tx aggregation size
+ * in no of MPDUs.This can be useful in debugging throughput issues
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal/External
+ *
+ *
+ */
+#define CFG_TX_AGGREGATION_SIZE CFG_INI_UINT( \
+ "gTxAggregationSize", \
+ 0, \
+ 64, \
+ 64, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx Aggregation size value")
+
+/*
+ *
+ * gTxAggregationSizeBE - To configure Tx aggregation size for BE queue
+ * in no of MPDUs
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggregationSizeBE gives an option to configure Tx aggregation size
+ * for BE queue in no of MPDUs.This can be useful in debugging
+ * throughput issues
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGREGATION_SIZEBE CFG_INI_UINT( \
+ "gTxAggregationSizeBE", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx Aggregation size value BE")
+
+/*
+ *
+ * gTxAggregationSizeBK - To configure Tx aggregation size for BK queue
+ * in no of MPDUs
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggregationSizeBK gives an option to configure Tx aggregation size
+ * for BK queue in no of MPDUs.This can be useful in debugging
+ * throughput issues
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGREGATION_SIZEBK CFG_INI_UINT( \
+ "gTxAggregationSizeBK", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx Aggregation size value BK")
+
+/*
+ *
+ * gTxAggregationSizeVI - To configure Tx aggregation size for VI queue
+ * in no of MPDUs
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggregationSizeVI gives an option to configure Tx aggregation size
+ * for VI queue in no of MPDUs.This can be useful in debugging
+ * throughput issues
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGREGATION_SIZEVI CFG_INI_UINT( \
+ "gTxAggregationSizeVI", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx Aggregation size value for VI")
+
+/*
+ *
+ * gTxAggregationSizeVO - To configure Tx aggregation size for VO queue
+ * in no of MPDUs
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggregationSizeVO gives an option to configure Tx aggregation size
+ * for BE queue in no of MPDUs.This can be useful in debugging
+ * throughput issues
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGREGATION_SIZEVO CFG_INI_UINT( \
+ "gTxAggregationSizeVO", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx Aggregation size value for VO")
+
+/*
+ *
+ * gRxAggregationSize - Gives an option to configure Rx aggregation size
+ * in no of MPDUs
+ * @Min: 1
+ * @Max: 64
+ * @Default: 64
+ *
+ * gRxAggregationSize gives an option to configure Rx aggregation size
+ * in no of MPDUs. This can be useful in debugging throughput issues
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal/External
+ *
+ *
+ */
+#define CFG_RX_AGGREGATION_SIZE CFG_INI_UINT( \
+ "gRxAggregationSize", \
+ 1, \
+ 64, \
+ 64, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Rx Aggregation size value")
+
+/*
+ *
+ * gTxAggSwRetryBE - Configure Tx aggregation sw retry for BE
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggSwRetryBE gives an option to configure Tx aggregation sw
+ * retry for BE. This can be useful in debugging throughput issues.
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGR_SW_RETRY_BE CFG_INI_UINT( \
+ "gTxAggSwRetryBE", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx aggregation retry value for BE")
+
+/*
+ *
+ * gTxAggSwRetryBK - Configure Tx aggregation sw retry for BK
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggSwRetryBK gives an option to configure Tx aggregation sw
+ * retry for BK. This can be useful in debugging throughput issues.
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGR_SW_RETRY_BK CFG_INI_UINT( \
+ "gTxAggSwRetryBK", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx aggregation retry value for BK")
+
+/*
+ *
+ * gTxAggSwRetryVI - Configure Tx aggregation sw retry for VI
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggSwRetryVI gives an option to configure Tx aggregation sw
+ * retry for VI. This can be useful in debugging throughput issues.
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGR_SW_RETRY_VI CFG_INI_UINT( \
+ "gTxAggSwRetryVI", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx aggregation retry value for VI")
+
+/*
+ *
+ * gTxAggSwRetryVO - Configure Tx aggregation sw retry for VO
+ * @Min: 0
+ * @Max: 64
+ * @Default: 0
+ *
+ * gTxAggSwRetryVO gives an option to configure Tx aggregation sw
+ * retry for VO. This can be useful in debugging throughput issues.
+ *
+ * Related: None
+ *
+ * Supported Feature: STA
+ *
+ * Usage: Internal
+ *
+ *
+ */
+#define CFG_TX_AGGR_SW_RETRY_VO CFG_INI_UINT( \
+ "gTxAggSwRetryVO", \
+ 0, \
+ 64, \
+ 0, \
+ CFG_VALUE_OR_DEFAULT, \
+ "Tx aggregation retry value for VO")
+
+/*
+ *
+ * gSapMaxInactivityOverride - Configure
+ * @Min: 0
+ * @Max: 1
+ * @Default: 0
+ *
+ * This parameter will avoid updating ap_sta_inactivity from hostapd.conf
+ * file. If a station does not send anything in ap_max_inactivity seconds, an
+ * empty data frame is sent to it in order to verify whether it is
+ * still in range. If this frame is not ACKed, the station will be
+ * disassociated and then deauthenticated. This feature is used to
+ * clear station table of old entries when the STAs move out of the
+ * range.
+ *
+ * Related: None
+ *
+ * Supported Feature: SAP
+ *
+ * Usage: Internal/External
+ *
+ */
+#define CFG_SAP_MAX_INACTIVITY_OVERRIDE CFG_INI_BOOL( \
+ "gSapMaxInactivityOverride", \
+ 0, \
+ "SAP maximum inactivity override flag")
+
+#define CFG_QOS_ALL \
+ CFG(CFG_TX_AGGREGATION_SIZE) \
+ CFG(CFG_TX_AGGREGATION_SIZEBE) \
+ CFG(CFG_TX_AGGREGATION_SIZEBK) \
+ CFG(CFG_TX_AGGREGATION_SIZEVI) \
+ CFG(CFG_TX_AGGREGATION_SIZEVO) \
+ CFG(CFG_RX_AGGREGATION_SIZE) \
+ CFG(CFG_TX_AGGR_SW_RETRY_BE) \
+ CFG(CFG_TX_AGGR_SW_RETRY_BK) \
+ CFG(CFG_TX_AGGR_SW_RETRY_VI) \
+ CFG(CFG_TX_AGGR_SW_RETRY_VO) \
+ CFG(CFG_SAP_MAX_INACTIVITY_OVERRIDE)
+
+#endif /* __CFG_MLME_QOS_H */
diff --git a/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h b/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h
index 636497aea3..e84a78c8eb 100644
--- a/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h
+++ b/components/mlme/dispatcher/inc/wlan_mlme_public_struct.h
@@ -120,6 +120,35 @@ struct wlan_mlme_vht_caps {
/* VHT related configs */
};
+/**
+ * struct wlan_mlme_qos - QOS TX/RX aggregation related CFG items
+ * @tx_aggregation_size: TX aggr size in number of MPDUs
+ * @tx_aggregation_size_be: No. of MPDUs for BE queue for TX aggr
+ * @tx_aggregation_size_bk: No. of MPDUs for BK queue for TX aggr
+ * @tx_aggregation_size_vi: No. of MPDUs for VI queue for TX aggr
+ * @tx_aggregation_size_vo: No. of MPDUs for VO queue for TX aggr
+ * @rx_aggregation_size: No. of MPDUs for RX aggr
+ * @tx_aggr_sw_retry_threshold_be: Tx aggregation sw retry for BE
+ * @tx_aggr_sw_retry_threshold_bk: Tx aggregation sw retry for BK
+ * @tx_aggr_sw_retry_threshold_vi: Tx aggregation sw retry for VI
+ * @tx_aggr_sw_retry_threshold_vo: Tx aggregation sw retry for VO
+ * @sap_max_inactivity_override: Override updating ap_sta_inactivity from
+ * hostapd.conf
+ */
+struct wlan_mlme_qos {
+ uint32_t tx_aggregation_size;
+ uint32_t tx_aggregation_size_be;
+ uint32_t tx_aggregation_size_bk;
+ uint32_t tx_aggregation_size_vi;
+ uint32_t tx_aggregation_size_vo;
+ uint32_t rx_aggregation_size;
+ uint32_t tx_aggr_sw_retry_threshold_be;
+ uint32_t tx_aggr_sw_retry_threshold_bk;
+ uint32_t tx_aggr_sw_retry_threshold_vi;
+ uint32_t tx_aggr_sw_retry_threshold_vo;
+ bool sap_max_inactivity_override;
+};
+
/**
* struct wlan_mlme_rates - RATES related config items
* @cfpPeriod: cfp period info
@@ -212,6 +241,7 @@ struct wlan_mlme_cfg {
struct wlan_mlme_ht_caps ht_caps;
struct wlan_mlme_obss_ht40 obss_ht40;
struct wlan_mlme_vht_caps vht_caps;
+ struct wlan_mlme_qos qos_mlme_params;
struct wlan_mlme_rates rates;
struct wlan_mlme_sap_protection sap_protection_cfg;
struct wlan_mlme_chainmask chainmask_cfg;