[dpdk-dev] Walk through a given mbuf-pool elements
Vithal S Mohare
vmohare at arubanetworks.com
Mon Dec 15 11:38:58 CET 2014
Hi Konstantin,
Thanks for the reply.
I was trying to find more intuitive one compare to rte_mempool_obj_iter(). Once mempool is created with objects, shouldn't we able to walk-through by just passing 'mp' object and avoiding other params like vaddr, elt_size etc. For now, I could use callback called during mempool creation itself.
Thanks,
-Vithal
-----Original Message-----
From: Ananyev, Konstantin [mailto:konstantin.ananyev at intel.com]
Sent: Monday, December 15, 2014 3:42 PM
To: Vithal S Mohare; dev at dpdk.org
Subject: RE: Walk through a given mbuf-pool elements
Hi Vithal,
> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Vithal S Mohare
> Sent: Monday, December 15, 2014 5:08 AM
> To: dev at dpdk.org
> Subject: [dpdk-dev] Walk through a given mbuf-pool elements
>
> [Re-sending the mail after registering to dpdk.org] Team,
>
> I am looking for a code/api to walk through a dpdk mbuf-pool elements (similar to rte_mempool_walk() but for elements within
> mempool). Calling pkt_mbuf_alloc for 'n' elements and then _free is not an option. Rte_mempool_obj_itr() walks through, but does
> lot more than walking itself. Please suggest if anybody has better alternatives.
Not sure why rte_mempool_obj_iter() wouldn't work for you?
It just walks through all elements of the pool and for ach calls a user provided callback.
Nothing else.
Konstantin
>
> Thanks,
> -Vithal
More information about the dev
mailing list