qcacld-3.0: Refactor one INI about obss ht40

Based on new cfg component, refactor INI CFG_OVERRIDE_HT40_20_24GHZ_NAME
and remove legacy codes.

Change-Id: I5b4ed96a4930a9358bd93ee809bf5cddb2787fb4
CRs-Fixed: 2354476
Cette révision appartient à :
Wu Gao
2018-11-22 11:38:41 +08:00
révisé par nshrivas
Parent 7f2ed98442
révision 223d3b7db9
5 fichiers modifiés avec 56 ajouts et 1 suppressions

Voir le fichier

@@ -1127,7 +1127,10 @@ static void mlme_init_obss_ht40_cfg(struct wlan_objmgr_psoc *psoc,
cfg_default(CFG_OBSS_HT40_WIDTH_CH_TRANSITION_DELAY);
obss_ht40->scan_activity_threshold = (uint32_t)
cfg_default(CFG_OBSS_HT40_SCAN_ACTIVITY_THRESHOLD);
obss_ht40->is_override_ht20_40_24g =
cfg_get(psoc, CFG_OBSS_HT40_OVERRIDE_HT40_20_24GHZ);
}
static void mlme_init_threshold_cfg(struct wlan_objmgr_psoc *psoc,
struct wlan_mlme_threshold *threshold)
{

Voir le fichier

@@ -196,6 +196,29 @@
CFG_VALUE_OR_DEFAULT, \
"obss ht40 width transition delay")
/*
* <ini>
* override_ht20_40_24g - Use channel bonding in 2.4GHz from supplicant
* @Min: 0
* @Max: 1
* @Default: 0
*
* This ini used to set whether use channel Bonding in 2.4GHz from supplicant
* if gChannelBondingMode24GHz is set
*
* Related: gChannelBondingMode24GHz
*
* Supported Feature: STA
*
* Usage: Internal/External
*
* </ini>
*/
#define CFG_OBSS_HT40_OVERRIDE_HT40_20_24GHZ CFG_INI_BOOL( \
"override_ht20_40_24g", \
0, \
"Use channel bonding in 24 GHz")
#define CFG_OBSS_HT40_ALL \
CFG(CFG_OBSS_HT40_SCAN_ACTIVE_DWELL_TIME) \
CFG(CFG_OBSS_HT40_SCAN_PASSIVE_DWELL_TIME) \
@@ -203,6 +226,7 @@
CFG(CFG_OBSS_HT40_SCAN_PASSIVE_TOTAL_PER_CHANNEL) \
CFG(CFG_OBSS_HT40_SCAN_ACTIVE_TOTAL_PER_CHANNEL) \
CFG(CFG_OBSS_HT40_SCAN_ACTIVITY_THRESHOLD) \
CFG(CFG_OBSS_HT40_WIDTH_CH_TRANSITION_DELAY)
CFG(CFG_OBSS_HT40_WIDTH_CH_TRANSITION_DELAY) \
CFG(CFG_OBSS_HT40_OVERRIDE_HT40_20_24GHZ)
#endif /* CFG_MLME_OBSS_HT40_H__ */

Voir le fichier

@@ -946,6 +946,7 @@ struct wlan_mlme_acs {
* @active_per_channel: obss scan active total duration per channel
* @width_trans_delay: obss width transition delay
* @scan_activity_threshold: obss scan activity threshold
* @is_override_ht20_40_24g: use channel bonding in 2.4 GHz
*/
struct wlan_mlme_obss_ht40 {
uint32_t active_dwelltime;
@@ -955,6 +956,7 @@ struct wlan_mlme_obss_ht40 {
uint32_t active_per_channel;
uint32_t width_trans_delay;
uint32_t scan_activity_threshold;
bool is_override_ht20_40_24g;
};
/**

Voir le fichier

@@ -740,6 +740,16 @@ QDF_STATUS
ucfg_mlme_get_tgt_gtx_usr_cfg(struct wlan_objmgr_psoc *psoc,
uint32_t *val);
/**
* ucfg_mlme_is_override_ht20_40_24g() - use channel bonding in 2.4 GHz or not
* @psoc: pointer to psoc object
* @val: Pointer to the value which will be filled for the caller
*
* Return: QDF Status
*/
QDF_STATUS
ucfg_mlme_is_override_ht20_40_24g(struct wlan_objmgr_psoc *psoc, bool *val);
/**
* ucfg_mlme_get_roaming_offload() - Get roaming offload setting
* @psoc: pointer to psoc object

Voir le fichier

@@ -331,6 +331,22 @@ ucfg_mlme_get_tgt_gtx_usr_cfg(struct wlan_objmgr_psoc *psoc,
return QDF_STATUS_SUCCESS;
}
QDF_STATUS
ucfg_mlme_is_override_ht20_40_24g(struct wlan_objmgr_psoc *psoc, bool *val)
{
struct wlan_mlme_psoc_obj *mlme_obj;
mlme_obj = mlme_get_psoc_obj(psoc);
if (!mlme_obj) {
*val = cfg_default(CFG_OBSS_HT40_OVERRIDE_HT40_20_24GHZ);
mlme_err("mlme obj null");
return QDF_STATUS_E_INVAL;
}
*val = mlme_obj->cfg.obss_ht40.is_override_ht20_40_24g;
return QDF_STATUS_SUCCESS;
}
QDF_STATUS
ucfg_mlme_get_roaming_offload(struct wlan_objmgr_psoc *psoc,
bool *val)