[dpdk-dev] [PATCH] ethdev: fix statistics description
john.mcnamara at intel.com
Wed Nov 2 10:07:47 CET 2016
> -----Original Message-----
> From: Dai, Wei
> Sent: Wednesday, November 2, 2016 8:29 AM
> To: Thomas Monjalon <thomas.monjalon at 6wind.com>; Mcnamara, John
> <john.mcnamara at intel.com>; Ananyev, Konstantin
> <konstantin.ananyev at intel.com>; Wu, Jingjing <jingjing.wu at intel.com>;
> Zhang, Helin <helin.zhang at intel.com>; Dai, Wei <wei.dai at intel.com>;
> Curran, Greg <greg.curran at intel.com>
> Cc: dev at dpdk.org
> Subject: RE: [dpdk-dev] [PATCH] ethdev: fix statistics description
> Hi, John & Greg
> Would you please give any opinion for this patch ?
> I have looked through all PMDs and found not all statistics items can be
> supported by some NIC.
> For example, rx_nombuf, q_ipackets, q_opackets, q_ibytes and q_obytes
> are not supported by i40e.
> But when the function rte_eth_stats_get(uint8_t port_id, struct
> rte_eth_stats *stats) is called for i40e PMD, Above un-supported
> statistics item in output stats are zero, this is not real value.
> So far, there is no way to know whether an item in struct rte_eth_stats is
> supported or not only from this structure definition.
> Maybe some structure member can be added to indicate each of statistics
> item valid or not.
> But this means ABI change.
> In following list, I list statistics support details of all PMDs.
> Hope it can be displayed in your screen.
Thanks for the analysis.
Perhaps we could an API that returns a struct, or otherwise, that indicated what stats are returned by a PMD. An application that required stats could call it once to establish what stats were available. It would have to be done in some way that wouldn't break ABI every time a new stat was added.
Harry, Remy, how would this fit in with the existing stats scheme or the new metrics library.
More information about the dev