qcacmn: Set fast_tx flag when ol_stats are disabled
Set fast_tx when ol_stats are disabled in ultra_fastpath to avoid Tx completion overhead. And also includes following fixes: cdp support to get jitter stats cdp support to set/get vow stats cdp support to get Sojourn Stats Change-Id: I8bdb176edbdf210b4dedfaa117f058f57bd17241 CRs-Fixed: 3604215
This commit is contained in:

committed by
Rahul Choudhary

parent
6bb232bd38
commit
37c16635b1
@@ -1348,6 +1348,7 @@ enum cdp_peer_param_type {
|
||||
* @CDP_ISOLATION: set isolation flag
|
||||
* @CDP_CONFIG_UNDECODED_METADATA_CAPTURE_ENABLE: Undecoded metadata capture
|
||||
* @CDP_CONFIG_RXDMA_BUF_RING_SIZE: RXDMA buffer ring size configure
|
||||
* @CDP_CONFIG_DELAY_STATS: set/get delay stats
|
||||
*/
|
||||
enum cdp_pdev_param_type {
|
||||
CDP_CONFIG_DEBUG_SNIFFER,
|
||||
@@ -1384,6 +1385,7 @@ enum cdp_pdev_param_type {
|
||||
CDP_ISOLATION,
|
||||
CDP_CONFIG_UNDECODED_METADATA_CAPTURE_ENABLE,
|
||||
CDP_CONFIG_RXDMA_BUF_RING_SIZE,
|
||||
CDP_CONFIG_DELAY_STATS,
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -1438,6 +1440,7 @@ enum cdp_pdev_param_type {
|
||||
* @cdp_pdev_param_tx_capture: set tx capture
|
||||
* @cdp_pdev_param_chn_noise_flr: set channel noise floor
|
||||
* @cdp_pdev_param_cfg_vow: set/get vow config
|
||||
* @cdp_pdev_param_cfg_delay_stats: set/get delayed stats
|
||||
* @cdp_pdev_param_tidq_override: set/get tid queue override
|
||||
* @cdp_pdev_param_mon_freq: set monitor frequency
|
||||
* @cdp_pdev_param_bss_color: configure bss color
|
||||
@@ -1527,6 +1530,7 @@ typedef union cdp_config_param_t {
|
||||
bool cdp_pdev_param_hmmc_tid_ovrd;
|
||||
bool cdp_pdev_param_fltr_neigh_peers;
|
||||
bool cdp_pdev_param_cfg_vow;
|
||||
bool cdp_pdev_param_cfg_delay_stats;
|
||||
bool cdp_pdev_param_fltr_mcast;
|
||||
bool cdp_pdev_param_fltr_none;
|
||||
bool cdp_pdev_param_fltr_ucast;
|
||||
@@ -1561,6 +1565,7 @@ typedef union cdp_config_param_t {
|
||||
int cdp_psoc_param_en_nss_cfg;
|
||||
int cdp_psoc_param_preferred_hw_mode;
|
||||
bool cdp_psoc_param_pext_stats;
|
||||
bool cdp_psoc_param_jitter_stats;
|
||||
|
||||
bool cdp_skip_bar_update;
|
||||
bool cdp_ipa_enabled;
|
||||
@@ -1767,6 +1772,7 @@ enum cdp_vdev_param_type {
|
||||
* @CDP_RX_PKT_TLV_SIZE: RX pkt tlv size
|
||||
* @CDP_CFG_AST_INDICATION_DISABLE: AST indication disable
|
||||
* @CDP_CFG_GET_MLO_OPER_MODE: Get MLO operation mode
|
||||
* @CDP_CFG_PEER_JITTER_STATS: Peer Jitter Stats
|
||||
*/
|
||||
enum cdp_psoc_param_type {
|
||||
CDP_ENABLE_RATE_STATS,
|
||||
@@ -1795,6 +1801,7 @@ enum cdp_psoc_param_type {
|
||||
CDP_RX_PKT_TLV_SIZE,
|
||||
CDP_CFG_AST_INDICATION_DISABLE,
|
||||
CDP_CFG_GET_MLO_OPER_MODE,
|
||||
CDP_CFG_PEER_JITTER_STATS,
|
||||
};
|
||||
|
||||
#ifdef CONFIG_AP_PLATFORM
|
||||
|
@@ -1865,9 +1865,8 @@ qdf_nbuf_t dp_tx_fast_send_be(struct cdp_soc_t *soc_hdl, uint8_t vdev_id,
|
||||
tx_desc->pdev = pdev;
|
||||
tx_desc->pkt_offset = 0;
|
||||
tx_desc->length = pkt_len;
|
||||
tx_desc->flags |= DP_TX_DESC_FLAG_SIMPLE;
|
||||
if (soc->hw_txrx_stats_en)
|
||||
tx_desc->flags |= DP_TX_DESC_FLAG_FASTPATH_SIMPLE;
|
||||
tx_desc->flags |= pdev->tx_fast_flag;
|
||||
|
||||
tx_desc->nbuf->fast_recycled = 1;
|
||||
|
||||
if (nbuf->is_from_recycler && nbuf->fast_xmit)
|
||||
|
@@ -8191,7 +8191,7 @@ static QDF_STATUS dp_get_pdev_param(struct cdp_soc_t *cdp_soc, uint8_t pdev_id,
|
||||
switch (param) {
|
||||
case CDP_CONFIG_VOW:
|
||||
val->cdp_pdev_param_cfg_vow =
|
||||
((struct dp_pdev *)pdev)->delay_stats_flag;
|
||||
((struct dp_pdev *)pdev)->vow_stats;
|
||||
break;
|
||||
case CDP_TX_PENDING:
|
||||
val->cdp_pdev_param_tx_pending = dp_get_tx_pending(pdev);
|
||||
@@ -8220,6 +8220,10 @@ static QDF_STATUS dp_get_pdev_param(struct cdp_soc_t *cdp_soc, uint8_t pdev_id,
|
||||
val->cdp_rxdma_buf_ring_size =
|
||||
wlan_cfg_get_rx_dma_buf_ring_size(((struct dp_pdev *)pdev)->wlan_cfg_ctx);
|
||||
break;
|
||||
case CDP_CONFIG_DELAY_STATS:
|
||||
val->cdp_pdev_param_cfg_delay_stats =
|
||||
((struct dp_pdev *)pdev)->delay_stats_flag;
|
||||
break;
|
||||
default:
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
@@ -8357,6 +8361,9 @@ static QDF_STATUS dp_set_pdev_param(struct cdp_soc_t *cdp_soc, uint8_t pdev_id,
|
||||
wlan_cfg_set_rx_dma_buf_ring_size(pdev->wlan_cfg_ctx,
|
||||
val.cdp_rxdma_buf_ring_size);
|
||||
break;
|
||||
case CDP_CONFIG_VOW:
|
||||
pdev->vow_stats = val.cdp_pdev_param_cfg_vow;
|
||||
break;
|
||||
default:
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
@@ -9070,6 +9077,9 @@ static QDF_STATUS dp_get_psoc_param(struct cdp_soc_t *cdp_soc,
|
||||
wlan_cfg_ctx = soc->wlan_cfg_ctx;
|
||||
|
||||
switch (param) {
|
||||
case CDP_ENABLE_RATE_STATS:
|
||||
val->cdp_psoc_param_en_rate_stats = soc->peerstats_enabled;
|
||||
break;
|
||||
case CDP_CFG_PEER_EXT_STATS:
|
||||
val->cdp_psoc_param_pext_stats =
|
||||
wlan_cfg_is_peer_ext_stats_enabled(wlan_cfg_ctx);
|
||||
@@ -9129,6 +9139,10 @@ static QDF_STATUS dp_get_psoc_param(struct cdp_soc_t *cdp_soc,
|
||||
case CDP_CFG_GET_MLO_OPER_MODE:
|
||||
val->cdp_psoc_param_mlo_oper_mode = dp_get_mldev_mode(soc);
|
||||
break;
|
||||
case CDP_CFG_PEER_JITTER_STATS:
|
||||
val->cdp_psoc_param_jitter_stats =
|
||||
wlan_cfg_is_peer_jitter_stats_enabled(soc->wlan_cfg_ctx);
|
||||
break;
|
||||
default:
|
||||
dp_warn("Invalid param: %u", param);
|
||||
break;
|
||||
@@ -14383,6 +14397,11 @@ static QDF_STATUS dp_pdev_init(struct cdp_soc_t *txrx_soc,
|
||||
dp_init_tso_stats(pdev);
|
||||
dp_init_link_peer_stats_enabled(pdev);
|
||||
|
||||
/* Initialize dp tx fast path flag */
|
||||
pdev->tx_fast_flag = DP_TX_DESC_FLAG_SIMPLE;
|
||||
if (soc->hw_txrx_stats_en)
|
||||
pdev->tx_fast_flag |= DP_TX_DESC_FLAG_FASTPATH_SIMPLE;
|
||||
|
||||
pdev->rx_fast_flag = false;
|
||||
dp_info("Mem stats: DMA = %u HEAP = %u SKB = %u",
|
||||
qdf_dma_mem_stats_read(),
|
||||
|
@@ -1687,7 +1687,8 @@ bool dp_tx_desc_set_ktimestamp(struct dp_vdev *vdev,
|
||||
qdf_unlikely(vdev->pdev->soc->wlan_cfg_ctx->pext_stats_enabled) ||
|
||||
qdf_unlikely(dp_tx_pkt_tracepoints_enabled()) ||
|
||||
qdf_unlikely(vdev->pdev->soc->peerstats_enabled) ||
|
||||
qdf_unlikely(dp_is_vdev_tx_delay_stats_enabled(vdev))) {
|
||||
qdf_unlikely(dp_is_vdev_tx_delay_stats_enabled(vdev)) ||
|
||||
qdf_unlikely(wlan_cfg_is_peer_jitter_stats_enabled(vdev->pdev->soc->wlan_cfg_ctx))) {
|
||||
tx_desc->timestamp = qdf_ktime_real_get();
|
||||
return true;
|
||||
}
|
||||
@@ -1701,7 +1702,8 @@ bool dp_tx_desc_set_ktimestamp(struct dp_vdev *vdev,
|
||||
if (qdf_unlikely(vdev->pdev->delay_stats_flag) ||
|
||||
qdf_unlikely(vdev->pdev->soc->wlan_cfg_ctx->pext_stats_enabled) ||
|
||||
qdf_unlikely(dp_tx_pkt_tracepoints_enabled()) ||
|
||||
qdf_unlikely(vdev->pdev->soc->peerstats_enabled)) {
|
||||
qdf_unlikely(vdev->pdev->soc->peerstats_enabled) ||
|
||||
qdf_unlikely(wlan_cfg_is_peer_jitter_stats_enabled(vdev->pdev->soc->wlan_cfg_ctx))) {
|
||||
tx_desc->timestamp = qdf_ktime_real_get();
|
||||
return true;
|
||||
}
|
||||
|
@@ -3552,6 +3552,9 @@ struct dp_pdev {
|
||||
uint8_t enhanced_stats_en:1,
|
||||
link_peer_stats:1;
|
||||
|
||||
/* Flag to indicate fast path Tx flags */
|
||||
uint32_t tx_fast_flag;
|
||||
|
||||
/* Flag to indicate fast RX */
|
||||
bool rx_fast_flag;
|
||||
|
||||
@@ -3675,6 +3678,8 @@ struct dp_pdev {
|
||||
|
||||
/* enable calculation of delay stats*/
|
||||
bool delay_stats_flag;
|
||||
/* vow stats */
|
||||
bool vow_stats;
|
||||
void *dp_txrx_handle; /* Advanced data path handle */
|
||||
uint32_t ppdu_id;
|
||||
bool first_nbuf;
|
||||
|
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
#include <dp_types.h>
|
||||
#include "dp_rx.h"
|
||||
#include "dp_tx.h"
|
||||
#include "dp_peer.h"
|
||||
#include <dp_htt.h>
|
||||
#include <dp_mon_filter.h>
|
||||
@@ -1824,6 +1825,11 @@ dp_enable_enhanced_stats(struct cdp_soc_t *soc, uint8_t pdev_id)
|
||||
|
||||
dp_mon_tx_enable_enhanced_stats(pdev);
|
||||
|
||||
/* reset the tx fast path flag, as enhanced stats are enabled */
|
||||
pdev->tx_fast_flag &= ~DP_TX_DESC_FLAG_SIMPLE;
|
||||
if (dp_soc->hw_txrx_stats_en)
|
||||
pdev->tx_fast_flag &= ~DP_TX_DESC_FLAG_FASTPATH_SIMPLE;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -1857,6 +1863,7 @@ dp_disable_enhanced_stats(struct cdp_soc_t *soc, uint8_t pdev_id)
|
||||
struct dp_pdev *pdev =
|
||||
dp_get_pdev_from_soc_pdev_id_wifi3((struct dp_soc *)soc,
|
||||
pdev_id);
|
||||
struct dp_soc *dp_soc = cdp_soc_t_to_dp_soc(soc);
|
||||
struct dp_mon_pdev *mon_pdev;
|
||||
|
||||
if (!pdev || !pdev->monitor_pdev)
|
||||
@@ -1879,6 +1886,11 @@ dp_disable_enhanced_stats(struct cdp_soc_t *soc, uint8_t pdev_id)
|
||||
FL("Failed to reset enhanced mode filters"));
|
||||
}
|
||||
|
||||
/* set the tx fast path flag, as enhanced stats are disabled */
|
||||
pdev->tx_fast_flag |= DP_TX_DESC_FLAG_SIMPLE;
|
||||
if (dp_soc->hw_txrx_stats_en)
|
||||
pdev->tx_fast_flag |= DP_TX_DESC_FLAG_FASTPATH_SIMPLE;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user