Regards,
Bala

On 15 June 2017 at 23:20, Honnappa Nagarahalli <
honnappa.nagaraha...@linaro.org> wrote:

> On 15 June 2017 at 10:58, Bala Manoharan <bala.manoha...@linaro.org>
> wrote:
> > On 15 June 2017 at 20:00, Francois Ozog <francois.o...@linaro.org>
> wrote:
> >
> >> I wonder then how packet receive in HW driven packet buffers is handled,
> >> may be with device memory....
> >>
> >> Can you explain the cases of packet receive with ODP application
> supplied
> >> (through packetio open) mempools?
> >>
> >
> > There needs to be atleast one pool linked to a pktio interface and there
> > can be more than one if application wants to configure different pools
> for
> > different flows. The configuration of the pool is given by the
> application
> > so that any traffic burst in a single flow does not overload the entire
> > system processing for other flows.
> >
> > So when application configures a packet pool we allocate internal shared
> > memory and pool allocator and link it to  the pktio interface. When
> packet
> > is received in the pktio interface the packet is allocated from the
> linked
> > pool.
>
> When you say 'internal shared memory', do you mean the memory is
> shared between the CPU cores and the hardware accelerators? I did not
> understand the 'pool allocator'. My understanding from your earlier
> email is that the pool is created (and all the packet buffers
> instantiated) when odp_pool_create API is called and pool is linked to
> the pktio in odp_pktio_open call.
>

'pool allocator' is a HW module which basically holds list of pointers from
a memory location and provides pointers when someone calls alloc from the
pool.
pool is created when you call odp_pool_create().
pktio is created with odp_pktio_open() which takes pool as an input
argument.
pool is linked to the pktio when you call odp_pktio_start()
Hope its clear.

Regards,
Bala

>
> >
> > Does this answer your question?
> >
> > Regards,
> > Bala
> >
> >>
> >> FF
> >>
> >> On 15 June 2017 at 15:42, Bala Manoharan <bala.manoha...@linaro.org>
> >> wrote:
> >>
> >>> Add on. It is also possible that the pool might not be linked to any
> pktio
> >>> eg buffer pools, hence in implementation we can not wait for the pool
> to
> >>> be
> >>> linked to pktio.
> >>>
> >>> Regards,
> >>> Bala
> >>>
> >>> On 15 June 2017 at 18:11, Bill Fischofer <bill.fischo...@linaro.org>
> >>> wrote:
> >>>
> >>> > A pool may be associated with a pktio at open time, but this
> >>> > association is not exclusive. In theory an ODP implementation could
> >>> > defer actual pool creation until it was first used, but such an
> >>> > approach would be unlikely to yield any real benefits while creating
> a
> >>> > lot of complications along the way since odp_pool_create() is the
> only
> >>> > opportunity the implementation has to fail the pool creation in a
> >>> > defined manner.
> >>> >
> >>> > On Thu, Jun 15, 2017 at 2:29 AM, Bala Manoharan
> >>> > <bala.manoha...@linaro.org> wrote:
> >>> > > Same here. Pool is created during odp_pool_create API.
> >>> > >
> >>> > >
> >>> > > Regards,
> >>> > > Bala
> >>> > >
> >>> > > On 15 June 2017 at 12:36, Nikhil Agarwal <nikhil.agar...@nxp.com>
> >>> wrote:
> >>> > >
> >>> > >> Pool is created at odp_pool_create only. You can allocate packets
> >>> form
> >>> > it
> >>> > >> even before pktio_open.
> >>> > >>
> >>> > >> Regards
> >>> > >> Nikhil
> >>> > >>
> >>> > >> -----Original Message-----
> >>> > >> From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org] On
> Behalf Of
> >>> > >> Honnappa Nagarahalli
> >>> > >> Sent: Thursday, June 15, 2017 9:27 AM
> >>> > >> To: lng-odp-forward <lng-odp@lists.linaro.org>
> >>> > >> Subject: [lng-odp] Mem pool creation in Cavium/NXP implementations
> >>> > >>
> >>> > >> Hi Bala/Nikhil,
> >>> > >>     I was wondering when is the memory pool created in your
> >>> > implementation
> >>> > >> of ODP? The programming model is that the application creates the
> >>> memory
> >>> > >> pool and passes that pool to the pkt I/O during packet I/O open
> >>> call. Do
> >>> > >> you actually create the pool when the application calls
> >>> > odp_pool_create? Or
> >>> > >> is the pool created during packet I/O open?
> >>> > >>
> >>> > >> Appreciate your answers.
> >>> > >>
> >>> > >> Thank you,
> >>> > >> Honnappa
> >>> > >>
> >>> >
> >>>
> >>
> >>
> >>
> >> --
> >> [image: Linaro] <http://www.linaro.org/>
> >> François-Frédéric Ozog | *Director Linaro Networking Group*
> >> T: +33.67221.6485
> >> francois.o...@linaro.org | Skype: ffozog
> >>
> >>
>

Reply via email to