qcacld-3.0: ADD MLME INI items of WMM Configuration

Add the following WMM config  ini configs to MLME cfg:

1. CFG_QOS_WMM_MODE_NAME
2. CFG_QOS_WMM_80211E_ENABLED_NAME
3. CFG_QOS_WMM_UAPSD_MASK_NAME
4. CFG_QOS_IMPLICIT_SETUP_ENABLED_NAME

Change-Id: I0c6354960b49d680e3efe304ea3300059c37015c
CRs-Fixed: 2327691
This commit is contained in:
Abhinav Kumar
2018-09-01 18:33:56 +05:30
committed by nshrivas
parent 2af8c12ac9
commit 7d6f1ac679
11 changed files with 409 additions and 136 deletions

View File

@@ -1308,6 +1308,15 @@ static void mlme_init_wmm_in_cfg(struct wlan_objmgr_psoc *psoc,
cfg_get(psoc, CFG_QOS_WMM_UAPSD_BK_SRV_INTV); cfg_get(psoc, CFG_QOS_WMM_UAPSD_BK_SRV_INTV);
wmm_params->ac_bk.uapsd_bk_sus_intv = wmm_params->ac_bk.uapsd_bk_sus_intv =
cfg_get(psoc, CFG_QOS_WMM_UAPSD_BK_SUS_INTV); cfg_get(psoc, CFG_QOS_WMM_UAPSD_BK_SUS_INTV);
wmm_params->wmm_config.wmm_mode =
cfg_get(psoc, CFG_QOS_WMM_MODE);
wmm_params->wmm_config.b80211e_is_enabled =
cfg_get(psoc, CFG_QOS_WMM_80211E_ENABLED);
wmm_params->wmm_config.uapsd_mask =
cfg_get(psoc, CFG_QOS_WMM_UAPSD_MASK);
wmm_params->wmm_config.bimplicit_qos_enabled =
cfg_get(psoc, CFG_QOS_WMM_IMPLICIT_SETUP_ENABLED);
} }
static void mlme_init_wps_params_cfg(struct wlan_objmgr_psoc *psoc, static void mlme_init_wps_params_cfg(struct wlan_objmgr_psoc *psoc,

View File

@@ -756,6 +756,101 @@
CFG_VALUE_OR_DEFAULT, \ CFG_VALUE_OR_DEFAULT, \
"Infra uapsd bk sus intv") "Infra uapsd bk sus intv")
/* WMM configuration */
/*
* <ini>
* WmmIsEnabled - Enable WMM feature
* @Min: 0
* @Max: 2
* @Default: 0
*
* This ini is used to enable/disable WMM.
*
* Related: None.
*
* Supported Feature: WMM
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_MODE CFG_INI_UINT( \
"WmmIsEnabled", \
0, \
2, \
2, \
CFG_VALUE_OR_DEFAULT, \
"Enable WMM feature")
/*
* <ini>
* 80211eIsEnabled - Enable 802.11e feature
* @Min: 0
* @Max: 1
* @Default: 0
*
* This ini is used to enable/disable 802.11e.
*
* Related: None.
*
* Supported Feature: 802.11e
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_80211E_ENABLED CFG_INI_BOOL( \
"80211eIsEnabled", \
0, \
"Enable 802.11e feature")
/*
* <ini>
* UapsdMask - To setup U-APSD mask for ACs
* @Min: 0x00
* @Max: 0xFF
* @Default: 0x00
*
* This ini is used to setup U-APSD mask for ACs.
*
* Related: None.
*
* Supported Feature: WMM
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_UAPSD_MASK CFG_INI_UINT( \
"UapsdMask", \
0x00, \
0xFF, \
0x00, \
CFG_VALUE_OR_DEFAULT, \
"setup U-APSD mask for ACs")
/*
* <ini>
* ImplicitQosIsEnabled - Enableimplicit QOS
* @Min: 0
* @Max: 1
* @Default: 0
*
* This ini is used to enable/disable implicit QOS.
*
* Related: None.
*
* Supported Feature: WMM
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_IMPLICIT_SETUP_ENABLED CFG_INI_BOOL( \
"ImplicitQosIsEnabled", \
0, \
"Enable implicit QOS")
#define CFG_WMM_PARAMS_ALL \ #define CFG_WMM_PARAMS_ALL \
CFG(CFG_QOS_ENABLED) \ CFG(CFG_QOS_ENABLED) \
CFG(CFG_WME_ENABLED) \ CFG(CFG_WME_ENABLED) \
@@ -789,6 +884,10 @@
CFG(CFG_QOS_WMM_MIN_PHY_RATE_AC_BK) \ CFG(CFG_QOS_WMM_MIN_PHY_RATE_AC_BK) \
CFG(CFG_QOS_WMM_SBA_AC_BK) \ CFG(CFG_QOS_WMM_SBA_AC_BK) \
CFG(CFG_QOS_WMM_UAPSD_BK_SRV_INTV) \ CFG(CFG_QOS_WMM_UAPSD_BK_SRV_INTV) \
CFG(CFG_QOS_WMM_UAPSD_BK_SUS_INTV) CFG(CFG_QOS_WMM_UAPSD_BK_SUS_INTV) \
CFG(CFG_QOS_WMM_MODE) \
CFG(CFG_QOS_WMM_80211E_ENABLED) \
CFG(CFG_QOS_WMM_UAPSD_MASK) \
CFG(CFG_QOS_WMM_IMPLICIT_SETUP_ENABLED)
#endif /* __CFG_MLME_FE_WMM_H */ #endif /* __CFG_MLME_FE_WMM_H */

View File

@@ -883,6 +883,47 @@ QDF_STATUS
wlan_mlme_get_wmm_uapsd_bk_sus_intv(struct wlan_objmgr_psoc *psoc, wlan_mlme_get_wmm_uapsd_bk_sus_intv(struct wlan_objmgr_psoc *psoc,
uint32_t *value); uint32_t *value);
/**
* wlan_mlme_get_wmm_mode() - Enable WMM feature
* @psoc: pointer to psoc object
* @value: pointer to the value which will be filled for the caller
*
* Return: QDF Status
*/
QDF_STATUS
wlan_mlme_get_wmm_mode(struct wlan_objmgr_psoc *psoc, uint8_t *value);
/**
* wlan_mlme_get_80211e_is_enabled() - Enable 802.11e feature
* @psoc: pointer to psoc object
* @value: pointer to the value which will be filled for the caller
*
* Return: QDF Status
*/
QDF_STATUS
wlan_mlme_get_80211e_is_enabled(struct wlan_objmgr_psoc *psoc, bool *value);
/**
* wlan_mlme_get_wmm_uapsd_mask() - setup U-APSD mask for ACs
* @psoc: pointer to psoc object
* @value: pointer to the value which will be filled for the caller
*
* Return: QDF Status
*/
QDF_STATUS
wlan_mlme_get_wmm_uapsd_mask(struct wlan_objmgr_psoc *psoc, uint8_t *value);
/**
* wlan_mlme_get_implicit_qos_is_enabled() - Enable implicit QOS
* @psoc: pointer to psoc object
* @value: pointer to the value which will be filled for the caller
*
* Return: QDF Status
*/
QDF_STATUS
wlan_mlme_get_implicit_qos_is_enabled(struct wlan_objmgr_psoc *psoc,
bool *value);
/** /**
* wlan_mlme_get_wmm_dir_ac_vo() - Get TSPEC direction * wlan_mlme_get_wmm_dir_ac_vo() - Get TSPEC direction
* for VO * for VO

View File

@@ -997,6 +997,20 @@ struct wlan_mlme_lfr_cfg {
uint32_t roam_preauth_no_ack_timeout; uint32_t roam_preauth_no_ack_timeout;
}; };
/**
* struct wlan_mlme_wmm_config - WMM configuration
* @wmm_mode: Enable WMM feature
* @b80211e_is_enabled: Enable 802.11e feature
* @uapsd_mask: what ACs to setup U-APSD for at assoc
* @bimplicit_qos_enabled: Enable implicit QOS
*/
struct wlan_mlme_wmm_config {
uint8_t wmm_mode;
bool b80211e_is_enabled;
uint8_t uapsd_mask;
bool bimplicit_qos_enabled;
};
/** /**
* struct wlan_mlme_wmm_ac_vo - Default TSPEC parameters * struct wlan_mlme_wmm_ac_vo - Default TSPEC parameters
* for AC_VO * for AC_VO
@@ -1100,6 +1114,7 @@ struct wlan_mlme_wmm_params {
uint8_t max_sp_length; uint8_t max_sp_length;
bool wsm_enabled; bool wsm_enabled;
uint32_t edca_profile; uint32_t edca_profile;
struct wlan_mlme_wmm_config wmm_config;
struct wlan_mlme_wmm_ac_vo ac_vo; struct wlan_mlme_wmm_ac_vo ac_vo;
struct wlan_mlme_wmm_ac_vi ac_vi; struct wlan_mlme_wmm_ac_vi ac_vi;
struct wlan_mlme_wmm_ac_be ac_be; struct wlan_mlme_wmm_ac_be ac_be;

View File

@@ -2049,4 +2049,65 @@ ucfg_mlme_get_wmm_uapsd_bk_sus_intv(struct wlan_objmgr_psoc *psoc,
return wlan_mlme_get_wmm_uapsd_bk_sus_intv(psoc, value); return wlan_mlme_get_wmm_uapsd_bk_sus_intv(psoc, value);
} }
/**
* ucfg_mlme_get_wmm_mode() - Enable WMM feature
* @psoc: pointer to psoc object
* @value: Value that needs to be set from the caller
*
* Inline UCFG API to be used by HDD/OSIF callers
*
* Return: QDF Status
*/
static inline QDF_STATUS
ucfg_mlme_get_wmm_mode(struct wlan_objmgr_psoc *psoc, uint8_t *value)
{
return wlan_mlme_get_wmm_mode(psoc, value);
}
/**
* ucfg_mlme_get_80211e_is_enabled() - Enable 802.11e feature
* @psoc: pointer to psoc object
* @value: Value that needs to be set from the caller
*
* Inline UCFG API to be used by HDD/OSIF callers
*
* Return: QDF Status
*/
static inline QDF_STATUS
ucfg_mlme_get_80211e_is_enabled(struct wlan_objmgr_psoc *psoc, bool *value)
{
return wlan_mlme_get_80211e_is_enabled(psoc, value);
}
/**
* ucfg_mlme_get_wmm_uapsd_mask() - setup U-APSD mask for ACs
* @psoc: pointer to psoc object
* @value: Value that needs to be set from the caller
*
* Inline UCFG API to be used by HDD/OSIF callers
*
* Return: QDF Status
*/
static inline QDF_STATUS
ucfg_mlme_get_wmm_uapsd_mask(struct wlan_objmgr_psoc *psoc, uint8_t *value)
{
return wlan_mlme_get_wmm_uapsd_mask(psoc, value);
}
/**
* ucfg_mlme_get_implicit_qos_is_enabled() - Enable implicit QOS
* @psoc: pointer to psoc object
* @value: Value that needs to be set from the caller
*
* Inline UCFG API to be used by HDD/OSIF callers
*
* Return: QDF Status
*/
static inline QDF_STATUS
ucfg_mlme_get_implicit_qos_is_enabled(struct wlan_objmgr_psoc *psoc,
bool *value)
{
return wlan_mlme_get_implicit_qos_is_enabled(psoc, value);
}
#endif /* _WLAN_MLME_UCFG_API_H_ */ #endif /* _WLAN_MLME_UCFG_API_H_ */

View File

@@ -1024,6 +1024,71 @@ wlan_mlme_get_wmm_uapsd_bk_sus_intv(struct wlan_objmgr_psoc *psoc,
return QDF_STATUS_SUCCESS; return QDF_STATUS_SUCCESS;
} }
QDF_STATUS
wlan_mlme_get_wmm_mode(struct wlan_objmgr_psoc *psoc, uint8_t *value)
{
struct wlan_mlme_psoc_obj *mlme_obj;
mlme_obj = mlme_get_psoc_obj(psoc);
if (!mlme_obj) {
mlme_err("Failed to get MLME Obj");
return QDF_STATUS_E_FAILURE;
}
*value = mlme_obj->cfg.wmm_params.wmm_config.wmm_mode;
return QDF_STATUS_SUCCESS;
}
QDF_STATUS
wlan_mlme_get_80211e_is_enabled(struct wlan_objmgr_psoc *psoc, bool *value)
{
struct wlan_mlme_psoc_obj *mlme_obj;
mlme_obj = mlme_get_psoc_obj(psoc);
if (!mlme_obj) {
mlme_err("Failed to get MLME Obj");
return QDF_STATUS_E_FAILURE;
}
*value = mlme_obj->cfg.wmm_params.wmm_config.b80211e_is_enabled;
return QDF_STATUS_SUCCESS;
}
QDF_STATUS
wlan_mlme_get_wmm_uapsd_mask(struct wlan_objmgr_psoc *psoc, uint8_t *value)
{
struct wlan_mlme_psoc_obj *mlme_obj;
mlme_obj = mlme_get_psoc_obj(psoc);
if (!mlme_obj) {
mlme_err("Failed to get MLME Obj");
return QDF_STATUS_E_FAILURE;
}
*value = mlme_obj->cfg.wmm_params.wmm_config.uapsd_mask;
return QDF_STATUS_SUCCESS;
}
QDF_STATUS
wlan_mlme_get_implicit_qos_is_enabled(struct wlan_objmgr_psoc *psoc,
bool *value)
{
struct wlan_mlme_psoc_obj *mlme_obj;
mlme_obj = mlme_get_psoc_obj(psoc);
if (!mlme_obj) {
mlme_err("Failed to get MLME Obj");
return QDF_STATUS_E_FAILURE;
}
*value = mlme_obj->cfg.wmm_params.wmm_config.bimplicit_qos_enabled;
return QDF_STATUS_SUCCESS;
}
QDF_STATUS wlan_mlme_set_sap_listen_interval(struct wlan_objmgr_psoc *psoc, QDF_STATUS wlan_mlme_set_sap_listen_interval(struct wlan_objmgr_psoc *psoc,
int value) int value)
{ {

View File

@@ -2653,72 +2653,6 @@ enum station_keepalive_method {
#define CFG_STA_KEEPALIVE_METHOD_DEFAULT (HDD_STA_KEEPALIVE_GRAT_ARP) #define CFG_STA_KEEPALIVE_METHOD_DEFAULT (HDD_STA_KEEPALIVE_GRAT_ARP)
/* WMM configuration */ /* WMM configuration */
/*
* <ini>
* WmmIsEnabled - Enable WMM feature
* @Min: 0
* @Max: 2
* @Default: 0
*
* This ini is used to enable/disable WMM.
*
* Related: None.
*
* Supported Feature: WMM
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_MODE_NAME "WmmIsEnabled"
#define CFG_QOS_WMM_MODE_MIN (0)
#define CFG_QOS_WMM_MODE_MAX (2) /* HDD_WMM_NO_QOS */
#define CFG_QOS_WMM_MODE_DEFAULT (0) /* HDD_WMM_AUTO */
/*
* <ini>
* 80211eIsEnabled - Enable 802.11e feature
* @Min: 0
* @Max: 1
* @Default: 0
*
* This ini is used to enable/disable 802.11e.
*
* Related: None.
*
* Supported Feature: 802.11e
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_80211E_ENABLED_NAME "80211eIsEnabled"
#define CFG_QOS_WMM_80211E_ENABLED_MIN (0)
#define CFG_QOS_WMM_80211E_ENABLED_MAX (1)
#define CFG_QOS_WMM_80211E_ENABLED_DEFAULT (0)
/*
* <ini>
* UapsdMask - To setup U-APSD mask for ACs
* @Min: 0x00
* @Max: 0xFF
* @Default: 0x00
*
* This ini is used to setup U-APSD mask for ACs.
*
* Related: None.
*
* Supported Feature: WMM
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_QOS_WMM_UAPSD_MASK_NAME "UapsdMask"
#define CFG_QOS_WMM_UAPSD_MASK_MIN (0x00)
#define CFG_QOS_WMM_UAPSD_MASK_MAX (0xFF)
#define CFG_QOS_WMM_UAPSD_MASK_DEFAULT (0x00)
/* /*
* <ini> * <ini>
* ImplicitQosIsEnabled - Enableimplicit QOS * ImplicitQosIsEnabled - Enableimplicit QOS
@@ -6640,9 +6574,6 @@ struct hdd_config {
uint8_t wow_data_inactivity_timeout; uint8_t wow_data_inactivity_timeout;
/* WMM QoS Configuration */ /* WMM QoS Configuration */
enum hdd_wmm_user_mode WmmMode;
bool b80211eIsEnabled;
uint8_t UapsdMask; /* what ACs to setup U-APSD for at assoc */
bool isFastRoamIniFeatureEnabled; bool isFastRoamIniFeatureEnabled;
bool MAWCEnabled; bool MAWCEnabled;
#ifdef FEATURE_WLAN_ESE #ifdef FEATURE_WLAN_ESE
@@ -6653,7 +6584,6 @@ struct hdd_config {
uint8_t RoamRssiDiff; uint8_t RoamRssiDiff;
bool isWESModeEnabled; bool isWESModeEnabled;
bool isRoamOffloadScanEnabled; bool isRoamOffloadScanEnabled;
bool bImplicitQosEnabled;
uint32_t DelayedTriggerFrmInt; uint32_t DelayedTriggerFrmInt;
@@ -7131,11 +7061,11 @@ struct reg_table_entry {
/** /**
* hdd_to_csr_wmm_mode() - Utility function to convert HDD to CSR WMM mode * hdd_to_csr_wmm_mode() - Utility function to convert HDD to CSR WMM mode
* *
* @enum hdd_wmm_user_mode - hdd WMM user mode * @uint8_t mode - hdd WMM user mode
* *
* Return: CSR WMM mode * Return: CSR WMM mode
*/ */
eCsrRoamWmmUserModeType hdd_to_csr_wmm_mode(enum hdd_wmm_user_mode mode); eCsrRoamWmmUserModeType hdd_to_csr_wmm_mode(uint8_t mode);
/* Function declarations and documenation */ /* Function declarations and documenation */
QDF_STATUS hdd_parse_config_ini(struct hdd_context *hdd_ctx); QDF_STATUS hdd_parse_config_ini(struct hdd_context *hdd_ctx);

View File

@@ -749,27 +749,6 @@ struct reg_table_entry g_registry_table[] = {
CFG_WOW_DATA_INACTIVITY_TIMEOUT_MIN, CFG_WOW_DATA_INACTIVITY_TIMEOUT_MIN,
CFG_WOW_DATA_INACTIVITY_TIMEOUT_MAX), CFG_WOW_DATA_INACTIVITY_TIMEOUT_MAX),
REG_VARIABLE(CFG_QOS_WMM_MODE_NAME, WLAN_PARAM_Integer,
struct hdd_config, WmmMode,
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
CFG_QOS_WMM_MODE_DEFAULT,
CFG_QOS_WMM_MODE_MIN,
CFG_QOS_WMM_MODE_MAX),
REG_VARIABLE(CFG_QOS_WMM_80211E_ENABLED_NAME, WLAN_PARAM_Integer,
struct hdd_config, b80211eIsEnabled,
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
CFG_QOS_WMM_80211E_ENABLED_DEFAULT,
CFG_QOS_WMM_80211E_ENABLED_MIN,
CFG_QOS_WMM_80211E_ENABLED_MAX),
REG_VARIABLE(CFG_QOS_WMM_UAPSD_MASK_NAME, WLAN_PARAM_HexInteger,
struct hdd_config, UapsdMask,
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
CFG_QOS_WMM_UAPSD_MASK_DEFAULT,
CFG_QOS_WMM_UAPSD_MASK_MIN,
CFG_QOS_WMM_UAPSD_MASK_MAX),
#ifdef FEATURE_WLAN_ESE #ifdef FEATURE_WLAN_ESE
REG_VARIABLE(CFG_QOS_WMM_INFRA_INACTIVITY_INTERVAL_NAME, REG_VARIABLE(CFG_QOS_WMM_INFRA_INACTIVITY_INTERVAL_NAME,
WLAN_PARAM_Integer, WLAN_PARAM_Integer,
@@ -858,13 +837,6 @@ struct reg_table_entry g_registry_table[] = {
CFG_TL_DELAYED_TRGR_FRM_INT_MIN, CFG_TL_DELAYED_TRGR_FRM_INT_MIN,
CFG_TL_DELAYED_TRGR_FRM_INT_MAX), CFG_TL_DELAYED_TRGR_FRM_INT_MAX),
REG_VARIABLE(CFG_QOS_IMPLICIT_SETUP_ENABLED_NAME, WLAN_PARAM_Integer,
struct hdd_config, bImplicitQosEnabled,
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
CFG_QOS_IMPLICIT_SETUP_ENABLED_DEFAULT,
CFG_QOS_IMPLICIT_SETUP_ENABLED_MIN,
CFG_QOS_IMPLICIT_SETUP_ENABLED_MAX),
REG_VARIABLE(CFG_RRM_ENABLE_NAME, WLAN_PARAM_Integer, REG_VARIABLE(CFG_RRM_ENABLE_NAME, WLAN_PARAM_Integer,
struct hdd_config, fRrmEnable, struct hdd_config, fRrmEnable,
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
@@ -3968,7 +3940,7 @@ QDF_STATUS hdd_set_policy_mgr_user_cfg(struct hdd_context *hdd_ctx)
return status; return status;
} }
eCsrRoamWmmUserModeType hdd_to_csr_wmm_mode(enum hdd_wmm_user_mode mode) eCsrRoamWmmUserModeType hdd_to_csr_wmm_mode(uint8_t mode)
{ {
switch (mode) { switch (mode) {
case HDD_WMM_USER_MODE_QBSS_ONLY: case HDD_WMM_USER_MODE_QBSS_ONLY:
@@ -4067,6 +4039,8 @@ QDF_STATUS hdd_set_sme_config(struct hdd_context *hdd_ctx)
tSmeConfigParams *smeConfig; tSmeConfigParams *smeConfig;
uint8_t rrm_capab_len; uint8_t rrm_capab_len;
mac_handle_t mac_handle = hdd_ctx->mac_handle; mac_handle_t mac_handle = hdd_ctx->mac_handle;
uint8_t wmm_mode = 0;
bool b80211e_is_enabled;
struct hdd_config *pConfig = hdd_ctx->config; struct hdd_config *pConfig = hdd_ctx->config;
@@ -4076,10 +4050,6 @@ QDF_STATUS hdd_set_sme_config(struct hdd_context *hdd_ctx)
return QDF_STATUS_E_NOMEM; return QDF_STATUS_E_NOMEM;
} }
hdd_debug("%s bWmmIsEnabled=%d 802_11e_enabled=%d dot11Mode=%d",
__func__, pConfig->WmmMode, pConfig->b80211eIsEnabled,
pConfig->dot11Mode);
/* Config params obtained from the registry /* Config params obtained from the registry
* To Do: set regulatory information here * To Do: set regulatory information here
*/ */
@@ -4127,9 +4097,24 @@ QDF_STATUS hdd_set_sme_config(struct hdd_context *hdd_ctx)
smeConfig->csrConfig.min_rest_time_conc = pConfig->min_rest_time_conc; smeConfig->csrConfig.min_rest_time_conc = pConfig->min_rest_time_conc;
smeConfig->csrConfig.idle_time_conc = pConfig->idle_time_conc; smeConfig->csrConfig.idle_time_conc = pConfig->idle_time_conc;
smeConfig->csrConfig.Is11eSupportEnabled = pConfig->b80211eIsEnabled; status = ucfg_mlme_get_80211e_is_enabled(hdd_ctx->psoc,
smeConfig->csrConfig.WMMSupportMode = &b80211e_is_enabled);
hdd_to_csr_wmm_mode(pConfig->WmmMode); if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get b80211e_is_enabled failed");
return QDF_STATUS_E_FAILURE;
}
smeConfig->csrConfig.Is11eSupportEnabled = b80211e_is_enabled;
status = ucfg_mlme_get_wmm_mode(hdd_ctx->psoc, &wmm_mode);
if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get wmm_mode failed");
return QDF_STATUS_E_FAILURE;
}
smeConfig->csrConfig.WMMSupportMode = hdd_to_csr_wmm_mode(wmm_mode);
hdd_debug("%s bWmmIsEnabled=%d 802_11e_enabled=%d dot11Mode=%d",
__func__, wmm_mode, b80211e_is_enabled,
pConfig->dot11Mode);
smeConfig->rrmConfig.rrm_enabled = pConfig->fRrmEnable; smeConfig->rrmConfig.rrm_enabled = pConfig->fRrmEnable;
smeConfig->rrmConfig.max_randn_interval = pConfig->nRrmRandnIntvl; smeConfig->rrmConfig.max_randn_interval = pConfig->nRrmRandnIntvl;

View File

@@ -6189,6 +6189,7 @@ __wlan_hdd_cfg80211_set_wifi_test_config(struct wiphy *wiphy,
QDF_STATUS status; QDF_STATUS status;
bool bval = false; bool bval = false;
uint8_t value = 0; uint8_t value = 0;
uint8_t wmm_mode = 0;
hdd_enter_dev(dev); hdd_enter_dev(dev);
@@ -6252,8 +6253,14 @@ __wlan_hdd_cfg80211_set_wifi_test_config(struct wiphy *wiphy,
hdd_to_csr_wmm_mode(HDD_WMM_USER_MODE_NO_QOS); hdd_to_csr_wmm_mode(HDD_WMM_USER_MODE_NO_QOS);
hdd_debug("wmm is disabled"); hdd_debug("wmm is disabled");
} else { } else {
status = ucfg_mlme_get_wmm_mode(hdd_ctx->psoc,
&wmm_mode);
if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get wmm_mode failed");
return QDF_STATUS_E_FAILURE;
}
sme_config->csrConfig.WMMSupportMode = sme_config->csrConfig.WMMSupportMode =
hdd_to_csr_wmm_mode(hdd_ctx->config->WmmMode); hdd_to_csr_wmm_mode(wmm_mode);
hdd_debug("using wmm default value"); hdd_debug("using wmm default value");
} }
update_sme_cfg = true; update_sme_cfg = true;
@@ -14809,6 +14816,8 @@ static int wlan_hdd_cfg80211_connect_start(struct hdd_adapter *adapter,
tSmeConfigParams *sme_config; tSmeConfigParams *sme_config;
uint8_t channel = 0; uint8_t channel = 0;
mac_handle_t mac_handle; mac_handle_t mac_handle;
uint8_t wmm_mode = 0;
uint8_t value = 0;
hdd_enter(); hdd_enter();
@@ -14866,14 +14875,25 @@ static int wlan_hdd_cfg80211_connect_start(struct hdd_adapter *adapter,
} }
hdd_set_connection_in_progress(true); hdd_set_connection_in_progress(true);
if (HDD_WMM_USER_MODE_NO_QOS == status = ucfg_mlme_get_wmm_mode(hdd_ctx->psoc, &wmm_mode);
(WLAN_HDD_GET_CTX(adapter))->config->WmmMode) { if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get wmm_mode failed");
status = -EINVAL;
goto ret_status;
}
if (HDD_WMM_USER_MODE_NO_QOS == wmm_mode) {
/*QoS not enabled in cfg file */ /*QoS not enabled in cfg file */
roam_profile->uapsd_mask = 0; roam_profile->uapsd_mask = 0;
} else { } else {
/*QoS enabled, update uapsd mask from cfg file */ /*QoS enabled, update uapsd mask from cfg file */
roam_profile->uapsd_mask = status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc,
(WLAN_HDD_GET_CTX(adapter))->config->UapsdMask; &value);
if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
status = -EINVAL;
goto ret_status;
}
roam_profile->uapsd_mask = value;
} }
roam_profile->SSIDs.numOfSSIDs = 1; roam_profile->SSIDs.numOfSSIDs = 1;

View File

@@ -156,19 +156,32 @@ static int hdd_ndi_start_bss(struct hdd_adapter *adapter,
uint32_t roam_id; uint32_t roam_id;
struct csr_roam_profile *roam_profile; struct csr_roam_profile *roam_profile;
mac_handle_t mac_handle; mac_handle_t mac_handle;
uint8_t wmm_mode = 0;
struct hdd_context *hdd_ctx;
uint8_t value = 0;
hdd_enter(); hdd_enter();
roam_profile = hdd_roam_profile(adapter); roam_profile = hdd_roam_profile(adapter);
hdd_ctx = WLAN_HDD_GET_CTX(adapter);
if (HDD_WMM_USER_MODE_NO_QOS == status = ucfg_mlme_get_wmm_mode(hdd_ctx->psoc, &wmm_mode);
(WLAN_HDD_GET_CTX(adapter))->config->WmmMode) { if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get wmm_mode failed");
return -EINVAL;
}
if (HDD_WMM_USER_MODE_NO_QOS == wmm_mode) {
/* QoS not enabled in cfg file*/ /* QoS not enabled in cfg file*/
roam_profile->uapsd_mask = 0; roam_profile->uapsd_mask = 0;
} else { } else {
/* QoS enabled, update uapsd mask from cfg file*/ /* QoS enabled, update uapsd mask from cfg file*/
roam_profile->uapsd_mask = status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc, &value);
(WLAN_HDD_GET_CTX(adapter))->config->UapsdMask; if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
return -EINVAL;
}
roam_profile->uapsd_mask = value;
} }
roam_profile->csrPersona = adapter->device_mode; roam_profile->csrPersona = adapter->device_mode;

View File

@@ -1017,7 +1017,7 @@ static void __hdd_wmm_do_implicit_qos(struct work_struct *work)
struct hdd_context *hdd_ctx; struct hdd_context *hdd_ctx;
mac_handle_t mac_handle; mac_handle_t mac_handle;
QDF_STATUS status = QDF_STATUS_SUCCESS; QDF_STATUS status = QDF_STATUS_SUCCESS;
uint8_t dir_ac = 0; uint8_t dir_ac, mask = 0;
uint16_t nom_msdu_size_ac = 0; uint16_t nom_msdu_size_ac = 0;
uint32_t rate_ac = 0; uint32_t rate_ac = 0;
uint16_t sba_ac = 0; uint16_t sba_ac = 0;
@@ -1062,9 +1062,13 @@ static void __hdd_wmm_do_implicit_qos(struct work_struct *work)
qosInfo.ts_info.up = SME_QOS_WMM_UP_VO; qosInfo.ts_info.up = SME_QOS_WMM_UP_VO;
/* Check if there is any valid configuration from framework */ /* Check if there is any valid configuration from framework */
if (HDD_PSB_CFG_INVALID == adapter->configured_psb) { if (HDD_PSB_CFG_INVALID == adapter->configured_psb) {
qosInfo.ts_info.psb = status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc,
((WLAN_HDD_GET_CTX(adapter))->config-> &mask);
UapsdMask & SME_QOS_UAPSD_VO) ? 1 : 0; if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
return;
}
qosInfo.ts_info.psb = (mask & SME_QOS_UAPSD_VO) ? 1 : 0;
} }
status = ucfg_mlme_get_wmm_dir_ac_vo(hdd_ctx->psoc, status = ucfg_mlme_get_wmm_dir_ac_vo(hdd_ctx->psoc,
&dir_ac); &dir_ac);
@@ -1129,9 +1133,13 @@ static void __hdd_wmm_do_implicit_qos(struct work_struct *work)
qosInfo.ts_info.up = SME_QOS_WMM_UP_VI; qosInfo.ts_info.up = SME_QOS_WMM_UP_VI;
/* Check if there is any valid configuration from framework */ /* Check if there is any valid configuration from framework */
if (HDD_PSB_CFG_INVALID == adapter->configured_psb) { if (HDD_PSB_CFG_INVALID == adapter->configured_psb) {
qosInfo.ts_info.psb = status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc,
((WLAN_HDD_GET_CTX(adapter))->config-> &mask);
UapsdMask & SME_QOS_UAPSD_VI) ? 1 : 0; if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
return;
}
qosInfo.ts_info.psb = (mask & SME_QOS_UAPSD_VI) ? 1 : 0;
} }
status = ucfg_mlme_get_wmm_dir_ac_vi( status = ucfg_mlme_get_wmm_dir_ac_vi(
hdd_ctx->psoc, &dir_ac); hdd_ctx->psoc, &dir_ac);
@@ -1196,9 +1204,13 @@ static void __hdd_wmm_do_implicit_qos(struct work_struct *work)
qosInfo.ts_info.up = SME_QOS_WMM_UP_BE; qosInfo.ts_info.up = SME_QOS_WMM_UP_BE;
/* Check if there is any valid configuration from framework */ /* Check if there is any valid configuration from framework */
if (HDD_PSB_CFG_INVALID == adapter->configured_psb) { if (HDD_PSB_CFG_INVALID == adapter->configured_psb) {
qosInfo.ts_info.psb = status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc,
((WLAN_HDD_GET_CTX(adapter))->config-> &mask);
UapsdMask & SME_QOS_UAPSD_BE) ? 1 : 0; if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
return;
}
qosInfo.ts_info.psb = (mask & SME_QOS_UAPSD_BE) ? 1 : 0;
} }
status = ucfg_mlme_get_wmm_dir_ac_be(hdd_ctx->psoc, &dir_ac); status = ucfg_mlme_get_wmm_dir_ac_be(hdd_ctx->psoc, &dir_ac);
if (!QDF_IS_STATUS_SUCCESS(status)) { if (!QDF_IS_STATUS_SUCCESS(status)) {
@@ -1260,9 +1272,13 @@ static void __hdd_wmm_do_implicit_qos(struct work_struct *work)
qosInfo.ts_info.up = SME_QOS_WMM_UP_BK; qosInfo.ts_info.up = SME_QOS_WMM_UP_BK;
/* Check if there is any valid configuration from framework */ /* Check if there is any valid configuration from framework */
if (HDD_PSB_CFG_INVALID == adapter->configured_psb) { if (HDD_PSB_CFG_INVALID == adapter->configured_psb) {
qosInfo.ts_info.psb = status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc,
((WLAN_HDD_GET_CTX(adapter))->config-> &mask);
UapsdMask & SME_QOS_UAPSD_BK) ? 1 : 0; if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
return;
}
qosInfo.ts_info.psb = (mask & SME_QOS_UAPSD_BK) ? 1 : 0;
} }
status = ucfg_mlme_get_wmm_dir_ac_bk(hdd_ctx->psoc, &dir_ac); status = ucfg_mlme_get_wmm_dir_ac_bk(hdd_ctx->psoc, &dir_ac);
@@ -1873,12 +1889,20 @@ QDF_STATUS hdd_wmm_acquire_access(struct hdd_adapter *adapter,
sme_ac_enum_type acType, bool *pGranted) sme_ac_enum_type acType, bool *pGranted)
{ {
struct hdd_wmm_qos_context *pQosContext; struct hdd_wmm_qos_context *pQosContext;
struct hdd_context *hdd_ctx;
bool enable;
QDF_STATUS status = QDF_STATUS_SUCCESS;
hdd_ctx = WLAN_HDD_GET_CTX(adapter);
QDF_TRACE(QDF_MODULE_ID_HDD_DATA, QDF_TRACE_LEVEL_DEBUG, QDF_TRACE(QDF_MODULE_ID_HDD_DATA, QDF_TRACE_LEVEL_DEBUG,
"%s: Entered for AC %d", __func__, acType); "%s: Entered for AC %d", __func__, acType);
if (!hdd_wmm_is_active(adapter) || status = ucfg_mlme_get_implicit_qos_is_enabled(hdd_ctx->psoc, &enable);
!(WLAN_HDD_GET_CTX(adapter))->config->bImplicitQosEnabled || if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get implicit_qos_is_enabled failed");
}
if (!hdd_wmm_is_active(adapter) || !(enable) ||
!adapter->hdd_wmm_status.wmmAcStatus[acType].wmmAcAccessRequired) { !adapter->hdd_wmm_status.wmmAcStatus[acType].wmmAcAccessRequired) {
/* either we don't want QoS or the AP doesn't support /* either we don't want QoS or the AP doesn't support
* QoS or we don't want to do implicit QoS * QoS or we don't want to do implicit QoS
@@ -2239,14 +2263,25 @@ QDF_STATUS hdd_wmm_get_uapsd_mask(struct hdd_adapter *adapter,
QDF_STATUS status; QDF_STATUS status;
struct hdd_context *hdd_ctx = WLAN_HDD_GET_CTX(adapter); struct hdd_context *hdd_ctx = WLAN_HDD_GET_CTX(adapter);
uint32_t uapsd_value = 0; uint32_t uapsd_value = 0;
uint8_t wmm_mode = 0;
if (HDD_WMM_USER_MODE_NO_QOS == status = ucfg_mlme_get_wmm_mode(hdd_ctx->psoc, &wmm_mode);
(WLAN_HDD_GET_CTX(adapter))->config->WmmMode) { if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get wmm_mode failed");
return QDF_STATUS_E_FAILURE;
}
if (HDD_WMM_USER_MODE_NO_QOS == wmm_mode) {
/* no QOS then no UAPSD */ /* no QOS then no UAPSD */
uapsdMask = 0; uapsdMask = 0;
} else { } else {
/* start with the default mask */ /* start with the default mask */
uapsdMask = (WLAN_HDD_GET_CTX(adapter))->config->UapsdMask; status = ucfg_mlme_get_wmm_uapsd_mask(hdd_ctx->psoc,
&uapsdMask);
if (!QDF_IS_STATUS_SUCCESS(status)) {
hdd_err("Get uapsd_mask failed");
return QDF_STATUS_E_FAILURE;
}
/* disable UAPSD for any ACs with a 0 Service Interval */ /* disable UAPSD for any ACs with a 0 Service Interval */
status = ucfg_mlme_get_wmm_uapsd_vo_srv_intv(hdd_ctx->psoc, status = ucfg_mlme_get_wmm_uapsd_vo_srv_intv(hdd_ctx->psoc,