qcacmn: Dump flow pool stats as part of periodic stats display
Dump flow pool stats even for low verbosity level as part of periodic stats display. Change-Id: Iea59d20b0a81cfd0bfdac65ad54a11fa33f30f2f CRs-Fixed: 3031168
This commit is contained in:

committed by
Madan Koyyalamudi

parent
719e90b6dc
commit
ccb6664db1
@@ -7475,7 +7475,7 @@ static struct cdp_cfg *dp_get_ctrl_pdev_from_vdev_wifi3(
|
||||
*
|
||||
* Return: outstanding tx
|
||||
*/
|
||||
static uint32_t dp_get_tx_pending(struct cdp_pdev *pdev_handle)
|
||||
static int32_t dp_get_tx_pending(struct cdp_pdev *pdev_handle)
|
||||
{
|
||||
struct dp_pdev *pdev = (struct dp_pdev *)pdev_handle;
|
||||
|
||||
@@ -9564,6 +9564,8 @@ static QDF_STATUS dp_txrx_dump_stats(struct cdp_soc_t *psoc, uint16_t value,
|
||||
case CDP_DUMP_TX_FLOW_POOL_INFO:
|
||||
if (level == QDF_STATS_VERBOSITY_LEVEL_HIGH)
|
||||
cdp_dump_flow_pool_info((struct cdp_soc_t *)soc);
|
||||
else
|
||||
dp_tx_dump_flow_pool_info_compact(soc);
|
||||
break;
|
||||
|
||||
case CDP_DP_NAPI_STATS:
|
||||
@@ -10899,6 +10901,7 @@ static QDF_STATUS dp_runtime_suspend(struct cdp_soc_t *soc_hdl, uint8_t pdev_id)
|
||||
struct dp_soc *soc = cdp_soc_t_to_dp_soc(soc_hdl);
|
||||
struct dp_pdev *pdev;
|
||||
uint8_t i;
|
||||
int32_t tx_pending;
|
||||
|
||||
pdev = dp_get_pdev_from_soc_pdev_id_wifi3(soc, pdev_id);
|
||||
if (!pdev) {
|
||||
@@ -10907,8 +10910,10 @@ static QDF_STATUS dp_runtime_suspend(struct cdp_soc_t *soc_hdl, uint8_t pdev_id)
|
||||
}
|
||||
|
||||
/* Abort if there are any pending TX packets */
|
||||
if (dp_get_tx_pending(dp_pdev_to_cdp_pdev(pdev)) > 0) {
|
||||
dp_init_info("%pK: Abort suspend due to pending TX packets", soc);
|
||||
tx_pending = dp_get_tx_pending(dp_pdev_to_cdp_pdev(pdev));
|
||||
if (tx_pending) {
|
||||
dp_init_info("%pK: Abort suspend due to pending TX packets %d",
|
||||
soc, tx_pending);
|
||||
|
||||
/* perform a force flush if tx is pending */
|
||||
for (i = 0; i < soc->num_tcl_data_rings; i++) {
|
||||
@@ -11376,6 +11381,7 @@ static QDF_STATUS dp_bus_suspend(struct cdp_soc_t *soc_hdl, uint8_t pdev_id)
|
||||
struct dp_pdev *pdev = dp_get_pdev_from_soc_pdev_id_wifi3(soc, pdev_id);
|
||||
int timeout = SUSPEND_DRAIN_WAIT;
|
||||
int drain_wait_delay = 50; /* 50 ms */
|
||||
int32_t tx_pending;
|
||||
|
||||
if (qdf_unlikely(!pdev)) {
|
||||
dp_err("pdev is NULL");
|
||||
@@ -11383,10 +11389,11 @@ static QDF_STATUS dp_bus_suspend(struct cdp_soc_t *soc_hdl, uint8_t pdev_id)
|
||||
}
|
||||
|
||||
/* Abort if there are any pending TX packets */
|
||||
while (dp_get_tx_pending((struct cdp_pdev *)pdev) > 0) {
|
||||
while ((tx_pending = dp_get_tx_pending((struct cdp_pdev *)pdev))) {
|
||||
qdf_sleep(drain_wait_delay);
|
||||
if (timeout <= 0) {
|
||||
dp_err("TX frames are pending, abort suspend");
|
||||
dp_info("TX frames are pending %d, abort suspend",
|
||||
tx_pending);
|
||||
return QDF_STATUS_E_TIMEOUT;
|
||||
}
|
||||
timeout = timeout - drain_wait_delay;
|
||||
|
Reference in New Issue
Block a user