qcacmn: Define cdp interface struct and API to fetch dp soc stats

Define a new cdp interface structure and API for soc stats for use
by upper layers to fetch dp soc stats.

Change-Id: I314e952546551003da2ca7f69b2e1aa23c126e66
Tento commit je obsažen v:
Harsh Kumar Bijlani
2021-07-02 17:33:27 +05:30
odevzdal Madan Koyyalamudi
rodič 238ae4b7f7
revize 0dcfff9b90
4 změnil soubory, kde provedl 81 přidání a 0 odebrání

Zobrazit soubor

@@ -489,6 +489,29 @@ cdp_txrx_get_peer_stats_param(ol_txrx_soc_handle soc, uint8_t vdev_id,
buf);
}
/**
* @brief Call to get soc stats
*
* @param soc - soc handle
* @soc_stats - buffer for cdp soc stats
* @return - QDF_STATUS
*/
static inline QDF_STATUS
cdp_host_get_soc_stats(ol_txrx_soc_handle soc, struct cdp_soc_stats *soc_stats)
{
if (!soc || !soc->ops) {
dp_cdp_debug("Invalid Instance");
QDF_BUG(0);
return QDF_STATUS_E_FAILURE;
}
if (!soc->ops->host_stats_ops ||
!soc->ops->host_stats_ops->txrx_get_soc_stats)
return QDF_STATUS_E_FAILURE;
return soc->ops->host_stats_ops->txrx_get_soc_stats(soc, soc_stats);
}
/**
* @brief Call to get peer stats
*