MCPcopy Create free account
hub / github.com/F-Stack/f-stack / rte_eth_xstats_reset

Function rte_eth_xstats_reset

dpdk/lib/ethdev/rte_ethdev.c:3678–3697  ·  view source on GitHub ↗

reset ethdev extended statistics */

Source from the content-addressed store, hash-verified

3676
3677/* reset ethdev extended statistics */
3678int
3679rte_eth_xstats_reset(uint16_t port_id)
3680{
3681 struct rte_eth_dev *dev;
3682
3683 RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV);
3684 dev = &rte_eth_devices[port_id];
3685
3686 /* implemented by the driver */
3687 if (dev->dev_ops->xstats_reset != NULL) {
3688 int ret = eth_err(port_id, (*dev->dev_ops->xstats_reset)(dev));
3689
3690 rte_eth_trace_xstats_reset(port_id, ret);
3691
3692 return ret;
3693 }
3694
3695 /* fallback to default */
3696 return rte_eth_stats_reset(port_id);
3697}
3698
3699static int
3700eth_dev_set_queue_stats_mapping(uint16_t port_id, uint16_t queue_id,

Callers 4

fs_xstats_resetFunction · 0.85
hn_vf_xstats_resetFunction · 0.85
nic_xstats_clearFunction · 0.85
nic_xstats_clearFunction · 0.85

Calls 2

eth_errFunction · 0.85
rte_eth_stats_resetFunction · 0.85

Tested by

no test coverage detected