diff options
| author | lifeng <lifeng@codeaurora.org> | 2017-02-24 12:26:54 +0800 |
|---|---|---|
| committer | Sandeep Puligilla <spuligil@codeaurora.org> | 2017-04-11 04:36:53 -0700 |
| commit | aab489eb886b52b1ed6ced40ea2a8ee5ad3ae056 (patch) | |
| tree | 87a7abed657e746c08854997f64b9ba19bc56e02 | |
| parent | c2b912e210848ce35160a036dc64e4342d06098a (diff) | |
qcacld-3.0: Support for configure wlan rts sifs,ampdu count
qcacld-2.0 to qcacld-3.0 propagation
Add support for host enable/disable rts sifs bursting, and set
default tx mpdu aggregation count.
CRs-Fixed: 1089478
Change-Id: Ieb63621f217ccd1a50b925ea4dda05fecad01387
| -rw-r--r-- | core/hdd/inc/qc_sap_ioctl.h | 2 | ||||
| -rw-r--r-- | core/hdd/inc/wlan_hdd_cfg.h | 37 | ||||
| -rw-r--r-- | core/hdd/src/wlan_hdd_cfg.c | 14 | ||||
| -rw-r--r-- | core/hdd/src/wlan_hdd_hostapd.c | 26 | ||||
| -rw-r--r-- | core/hdd/src/wlan_hdd_main.c | 13 |
5 files changed, 92 insertions, 0 deletions
diff --git a/core/hdd/inc/qc_sap_ioctl.h b/core/hdd/inc/qc_sap_ioctl.h index a87869fa8857..07b5c05cfc3f 100644 --- a/core/hdd/inc/qc_sap_ioctl.h +++ b/core/hdd/inc/qc_sap_ioctl.h @@ -247,6 +247,8 @@ enum { QCASAP_PARAM_TX_STBC, QCASAP_PARAM_RX_STBC, QCSAP_PARAM_CHAN_WIDTH, + QCSAP_SET_DEFAULT_AMPDU, + QCSAP_ENABLE_RTS_BURSTING, }; int iw_get_channel_list(struct net_device *dev, diff --git a/core/hdd/inc/wlan_hdd_cfg.h b/core/hdd/inc/wlan_hdd_cfg.h index ccce3f6583bc..603682eb7780 100644 --- a/core/hdd/inc/wlan_hdd_cfg.h +++ b/core/hdd/inc/wlan_hdd_cfg.h @@ -10558,6 +10558,41 @@ enum dot11p_mode { #define CFG_ENABLE_ANI_MAX (1) #define CFG_ENABLE_ANI_DEFAULT (1) +/** + * gSetRTSForSIFSBursting - set rts for sifs bursting + * @Min: 0 + * @Max: 1 + * @Default: 0 + * + * This ini set rts for sifs bursting + * + * Usage: External + * + * </ini> + */ +#define CFG_SET_RTS_FOR_SIFS_BURSTING "gSetRTSForSIFSBursting" +#define CFG_SET_RTS_FOR_SIFS_BURSTING_MIN (0) +#define CFG_SET_RTS_FOR_SIFS_BURSTING_MAX (1) +#define CFG_SET_RTS_FOR_SIFS_BURSTING_DEFAULT (0) + +/** + * <ini> + * gMaxMPDUsInAMPDU - max mpdus in ampdu + * @Min: 0 + * @Max: 64 + * @Default: 0 + * + * This ini configure max mpdus in ampdu + * + * Usage: External + * + * </ini> + */ +#define CFG_MAX_MPDUS_IN_AMPDU "gMaxMPDUsInAMPDU" +#define CFG_MAX_MPDUS_IN_AMPDU_MIN (0) +#define CFG_MAX_MPDUS_IN_AMPDU_MAX (64) +#define CFG_MAX_MPDUS_IN_AMPDU_DEFAULT (0) + /*--------------------------------------------------------------------------- Type declarations -------------------------------------------------------------------------*/ @@ -11316,6 +11351,8 @@ struct hdd_config { uint16_t pkt_err_disconn_th; uint16_t reduced_beacon_interval; bool ani_enabled; + uint8_t enable_rts_sifsbursting; + uint8_t max_mpdus_inampdu; }; #define VAR_OFFSET(_Struct, _Var) (offsetof(_Struct, _Var)) diff --git a/core/hdd/src/wlan_hdd_cfg.c b/core/hdd/src/wlan_hdd_cfg.c index 3c72c053191f..df13dd9ad90a 100644 --- a/core/hdd/src/wlan_hdd_cfg.c +++ b/core/hdd/src/wlan_hdd_cfg.c @@ -4528,6 +4528,20 @@ struct reg_table_entry g_registry_table[] = { CFG_ENABLE_ANI_DEFAULT, CFG_ENABLE_ANI_MIN, CFG_ENABLE_ANI_MAX), + + REG_VARIABLE(CFG_SET_RTS_FOR_SIFS_BURSTING, WLAN_PARAM_Integer, + struct hdd_config, enable_rts_sifsbursting, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_SET_RTS_FOR_SIFS_BURSTING_DEFAULT, + CFG_SET_RTS_FOR_SIFS_BURSTING_MIN, + CFG_SET_RTS_FOR_SIFS_BURSTING_MAX), + + REG_VARIABLE(CFG_MAX_MPDUS_IN_AMPDU, WLAN_PARAM_Integer, + struct hdd_config, max_mpdus_inampdu, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_MAX_MPDUS_IN_AMPDU_DEFAULT, + CFG_MAX_MPDUS_IN_AMPDU_MIN, + CFG_MAX_MPDUS_IN_AMPDU_MAX), }; /** diff --git a/core/hdd/src/wlan_hdd_hostapd.c b/core/hdd/src/wlan_hdd_hostapd.c index 6c4aeb38325d..7297c1646562 100644 --- a/core/hdd/src/wlan_hdd_hostapd.c +++ b/core/hdd/src/wlan_hdd_hostapd.c @@ -3296,6 +3296,19 @@ static __iw_softap_setparam(struct net_device *dev, case QCASAP_PARAM_RX_STBC: ret = hdd_set_rx_stbc(pHostapdAdapter, set_value); break; + case QCSAP_SET_DEFAULT_AMPDU: + hdd_notice("QCSAP_SET_DEFAULT_AMPDU val %d", set_value); + ret = wma_cli_set_command((int)pHostapdAdapter->sessionId, + (int)WMI_PDEV_PARAM_MAX_MPDUS_IN_AMPDU, + set_value, PDEV_CMD); + break; + + case QCSAP_ENABLE_RTS_BURSTING: + hdd_notice("QCSAP_ENABLE_RTS_BURSTING val %d", set_value); + ret = wma_cli_set_command((int)pHostapdAdapter->sessionId, + (int)WMI_PDEV_PARAM_ENABLE_RTS_SIFS_BURSTING, + set_value, PDEV_CMD); + break; default: hdd_err("Invalid setparam command %d value %d", @@ -5757,6 +5770,19 @@ static const struct iw_priv_args hostapd_private_args[] = { IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 2, 0, "set_hist_intvl" } + , + { QCSAP_SET_DEFAULT_AMPDU, + IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, + 0, + "def_ampdu" + } + , + { QCSAP_ENABLE_RTS_BURSTING, + IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, + 0, + "rts_bursting" + } + , }; static const iw_handler hostapd_private[] = { diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index 6f31ab843ed4..299d1caf928e 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -8860,6 +8860,19 @@ int hdd_wlan_startup(struct device *dev) sme_set_chip_pwr_save_fail_cb(hdd_ctx->hHal, hdd_chip_pwr_save_fail_detected_cb); + if (hdd_ctx->config->max_mpdus_inampdu) { + set_value = hdd_ctx->config->max_mpdus_inampdu; + wma_cli_set_command(0, (int)WMI_PDEV_PARAM_MAX_MPDUS_IN_AMPDU, + set_value, PDEV_CMD); + } + + if (hdd_ctx->config->enable_rts_sifsbursting) { + set_value = hdd_ctx->config->enable_rts_sifsbursting; + wma_cli_set_command(0, + (int)WMI_PDEV_PARAM_ENABLE_RTS_SIFS_BURSTING, + set_value, PDEV_CMD); + } + qdf_mc_timer_start(&hdd_ctx->iface_change_timer, hdd_ctx->config->iface_change_wait_time); |
