qcacld-3.0: Add INI to configure MGMT frame HW retry count

Add INI - mgmt_frame_hw_tx_retry_count to configure MGMT
frame HW tx retry count for certain frame types.
The INI String format:
frame_hw_tx_retry_count="<frame type>,<retry count>,..."

The supported frame types are defined by enum mlme_cfg_frame_type.
Retry count max value is 127.
For example:
mgmt_frame_hw_tx_retry_count="0,64,2,32"
The above input string means:
For p2p go negotiation request fame, hw retry count 64
For p2p provision discovery request, hw retry count 32

Change-Id: I32f6c7d83ede9b28484c7a0b29824bde32e06422
CRs-Fixed: 3082532
This commit is contained in:
Liangwei Dong
2021-11-23 11:09:03 +08:00
committed by Madan Koyyalamudi
parent b93d2939d0
commit a185d29d1b
6 changed files with 199 additions and 3 deletions

View File

@@ -353,6 +353,49 @@ static void mlme_init_wds_config_cfg(struct wlan_objmgr_psoc *psoc,
}
#endif
/**
* mlme_init_mgmt_hw_tx_retry_count_cfg() - initialize mgmt hw tx retry count
* @psoc: Pointer to PSOC
* @gen: pointer to generic CFG items
*
* Return: None
*/
static void mlme_init_mgmt_hw_tx_retry_count_cfg(
struct wlan_objmgr_psoc *psoc,
struct wlan_mlme_generic *gen)
{
uint32_t i;
qdf_size_t out_size = 0;
uint8_t count_array[MGMT_FRM_HW_TX_RETRY_COUNT_STR_LEN];
qdf_uint8_array_parse(cfg_get(psoc, CFG_MGMT_FRAME_HW_TX_RETRY_COUNT),
count_array,
MGMT_FRM_HW_TX_RETRY_COUNT_STR_LEN,
&out_size);
for (i = 0; i + 1 < out_size; i += 2) {
if (count_array[i] >= CFG_FRAME_TYPE_MAX) {
mlme_legacy_debug("invalid frm type %d",
count_array[i]);
continue;
}
if (count_array[i + 1] >= MAX_MGMT_HW_TX_RETRY_COUNT) {
mlme_legacy_debug("mgmt hw tx retry count %d for frm %d, limit to %d",
count_array[i + 1],
count_array[i],
MAX_MGMT_HW_TX_RETRY_COUNT);
gen->mgmt_hw_tx_retry_count[count_array[i]] =
MAX_MGMT_HW_TX_RETRY_COUNT;
} else {
mlme_legacy_debug("mgmt hw tx retry count %d for frm %d",
count_array[i + 1],
count_array[i]);
gen->mgmt_hw_tx_retry_count[count_array[i]] =
count_array[i + 1];
}
}
}
static void mlme_init_generic_cfg(struct wlan_objmgr_psoc *psoc,
struct wlan_mlme_generic *gen)
{
@@ -416,6 +459,7 @@ static void mlme_init_generic_cfg(struct wlan_objmgr_psoc *psoc,
cfg_get(psoc, CFG_MONITOR_MODE_CONCURRENCY);
gen->tx_retry_multiplier = cfg_get(psoc, CFG_TX_RETRY_MULTIPLIER);
mlme_init_wds_config_cfg(psoc, gen);
mlme_init_mgmt_hw_tx_retry_count_cfg(psoc, gen);
}
static void mlme_init_edca_ani_cfg(struct wlan_objmgr_psoc *psoc,