-----Original Message-----
> Date: Mon, 15 Jan 2018 19:54:36 +0530
> From: Hemant Agrawal <hemant.agra...@nxp.com>
> To: Jerin Jacob <jerin.ja...@caviumnetworks.com>
> CC: dev@dpdk.org, olivier.m...@6wind.com, santosh.shu...@caviumnetworks.com
> Subject: Re: [PATCH v2 3/5] mbuf: support register mempool Hw ops name APIs
> User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101
>  Thunderbird/45.8.0
> 
> On 1/15/2018 5:11 PM, Jerin Jacob wrote:
> > > 
> > > +int
> > > +rte_mbuf_register_platform_mempool_ops(const char *ops_name)
> > > +{
> > 
> > Should we also check the following?
> > 
> > if (internal_config.plat_mbuf_pool_ops_name != NULL &&
> > strncmp(internal_config.plat_mbuf_pool_ops_name, ops_name, ..) == 0)
> >     return 0;
> > 
> > i.e avoid returning error if the same the driver but another
> > instance(different ethdev port) updates the same ops_name value.
> > 
> 
> No, there shall be only one default platform hw pool name.
> Any ethdev driven (may be weight based) replacement shall be dealt
> separately.

OK. Who calls the rte_mbuf_register_platform_mempool_ops() and when?
mempool ops registration is using gcc construction scheme so it will 
be called all the time. I thought, ethdev drivers will call this API on
pci or any other bus probe() and if its in probe() then 
rte_mbuf_register_platform_mempool_ops() will be called multiple time.

What is your thought on this API usage?

> 

Reply via email to