As currently defined, there is a many-to-one mapping between CoS and pools,
but a single CoS can only be associated with a single pool.  PMRs are used
to determine which CoS an incoming packet will be assigned to, and hence to
the pool it will reside in.  It is an application responsibility to ensure
that PMRs are unambiguously defined.  If this restriction is not observed,
it is undefined which PMR will apply, so behavior may vary cross different
ODP implementations.

For the shared interface question, this is a question of virtualization of
the interface.  From the perspective of multiple ODP applications each
interface (virtual or real) is dedicated to it, so the different pool
assignments for the various applications are all orthogonal.  Whether a
given interface can support such virtualization/multiplexing/sharing is up
to the given platform.  ODP itself does not specify whether or how such
restrictions may apply in any given instance.

On Fri, Apr 3, 2015 at 11:53 AM, Bala Manoharan <[email protected]>
wrote:

> On 3 April 2015 at 22:00, Taras Kondratiuk <[email protected]>
> wrote:
> > On 03/30/2015 03:34 PM, Zhujianhua wrote:
> >>
> >> @ Jerin Jacob:
> >> What will happen if odp_cos_set_pool(odp_cos_t cos_id, odp_buffer_pool_t
> >> pool_id) was called twice?
> >> Will the new pool_id replace the old one or the CoS have two pools?
> >>
> >> @Taras:
> >> Assume: set several pools per pktio interface.
> >> What will happen if two data plane applications share one physical
> >> Ethernet port to receive packets?
> >> Since the pool is per pktio interface, will these two applications share
> >> the same buffer pool?
> >> If there is memory leak in one application, the other application will
> be
> >> disturbed.
> >> Correct me if my understanding were wrong.
> >
> >
> > That's a nice question. I'm afraid this use-case was not considered
> before.
> > Do you want to split traffic between two applications via classifier?
> >
> >>
> >> Maybe to let each CoS have more than one pool and limit the max number
> of
> >> Pool to for example 4 (Let the application designer decide how many
> pools
> >> are needed for each CoS) could be one option.
>
> Hi,
>
> If we are attaching multiple pools per CoS what will be the
> distribution algorithm for packets to each of the associated pools?
> will it be a simple round-robin in that case wouldn't it be better to
> attach a single pool of bigger size to the specific CoS?
>
> Since we are attaching pools per CoS object the application can
> configure the PMR rule in such a way that packets which come from the
> same interface and belong to different service can be configured to be
> allocated from multiple pools by attaching to multiple CoS objects.
> Pls let me know if my understanding is wrong.
>
> Regards,
> Bala
> >
> >
> > That is a possible solution.
> > _______________________________________________
> > lng-odp mailing list
> > [email protected]
> > https://lists.linaro.org/mailman/listinfo/lng-odp
> _______________________________________________
> lng-odp mailing list
> [email protected]
> https://lists.linaro.org/mailman/listinfo/lng-odp
>
_______________________________________________
lng-odp mailing list
[email protected]
https://lists.linaro.org/mailman/listinfo/lng-odp

Reply via email to