> From: Ferruh Yigit [mailto:ferruh.yi...@amd.com] > Sent: Friday, 26 April 2024 15.38 > > On 4/26/2024 12:33 PM, Morten Brørup wrote:
[...] > > While reviewing, I came across the rx_mbuf_alloc_failed counter in the > rte_eth_dev_data structure: > > https://elixir.bootlin.com/dpdk/v24.03/source/lib/ethdev/rte_ethdev.c#L3145 > > > https://elixir.bootlin.com/dpdk/v24.03/source/lib/ethdev/ethdev_driver.h#L127 > > > > Doesn't it have the same problem? > > > > stats reset problem? af_packet is not collecting 'rx_mbuf_alloc_failed', > so nothing to do there for af_packet. Agreed, not related to af_packet or this patch. I'm just wondering if a similar or other patch should be applied to rx_mbuf_alloc_failed in the ethdev layer. rx_mbuf_alloc_failed is shared by lcores, so perhaps it should be atomic, or atomically incremented by drivers using it. > > > > > BTW, the af_packet PMD doesn't increase the rx_mbuf_alloc_failed counter on > mbuf allocation failures. But that's a separate bug. > > > > Yes it is missing, but I wouldn't call it a bug, just one of the stats > is missing. And yes this can be handled separately if required. OK, then just some stats missing, not a bug. Quite useful stats for debugging a production system, if mbuf allocations fail. But still, not related to this patch.