On 6/2/2016 8:04 AM, Olivier MATZ wrote: > Hi Ferruh, > > Thank you for fixing this issue. > > On 06/01/2016 03:18 PM, Ferruh Yigit wrote: >> [PATCH] ivshmem: add all memzones of mempool to metada > > Minor comment: it seems the title is truncated >
Right, I will fix in next version of patch. >> +static int >> +add_mempool_to_metadata(const struct rte_mempool *mp, >> + struct ivshmem_config *config) >> +{ >> + struct rte_mempool_memhdr *memhdr; >> + int ret; >> + >> + ret = add_mempool_memzone_to_metadata(mp, config); >> if (ret < 0) >> return -1; >> >> + STAILQ_FOREACH(memhdr, &mp->mem_list, next) { >> + ret = add_mempool_memzone_to_metadata(memhdr->addr, config); >> + if (ret < 0) >> + return -1; >> + } >> + >> + /* mempool consists of memzone and ring */ >> return add_ring_to_metadata(mp->ring, config); >> } >> > > In case you missed it: there is a function > rte_mempool_mem_iter() that can be used to browse the > memory chunks of a mempool. It's probably less convenient > to use compared to directly browsing the list, but it > may be more resistant to api changes. I wasn't aware rte_mempool_mem_iter(), I will update the patch to use this. > > Apart from that: > Acked-by: Olivier Matz <olivier.matz at 6wind.com> > > Thanks > Thanks, ferruh