On Mon, Feb 06, 2017 at 10:25:18AM +0000, Van Haaren, Harry wrote: > > -----Original Message----- > > From: Jerin Jacob [mailto:jerin.ja...@caviumnetworks.com] > > Sent: Monday, February 6, 2017 9:25 AM > > To: Van Haaren, Harry <harry.van.haa...@intel.com> > > Cc: dev@dpdk.org; Richardson, Bruce <bruce.richard...@intel.com> > > Subject: Re: [PATCH v2 07/15] event/sw: add support for event queues > > > > On Tue, Jan 31, 2017 at 04:14:25PM +0000, Harry van Haaren wrote: > > > From: Bruce Richardson <bruce.richard...@intel.com> > > > > > > Add in the data structures for the event queues, and the eventdev > > > functions to create and destroy those queues. > > > > > > Signed-off-by: Bruce Richardson <bruce.richard...@intel.com> > > > Signed-off-by: Harry van Haaren <harry.van.haa...@intel.com> > > > --- > > > drivers/event/sw/iq_ring.h | 176 > > > ++++++++++++++++++++++++++++++++++++++++++++ > > > drivers/event/sw/sw_evdev.c | 158 +++++++++++++++++++++++++++++++++++++++ > > > drivers/event/sw/sw_evdev.h | 75 +++++++++++++++++++ > > > 3 files changed, 409 insertions(+) > > > create mode 100644 drivers/event/sw/iq_ring.h > > > > > > + */ > > > + > > > +/* > > > + * Ring structure definitions used for the internal ring buffers of the > > > + * SW eventdev implementation. These are designed for single-core use > > > only. > > > + */ > > > > If I understand it correctly, IQ and QE rings are single producer and > > single consumer rings. By the specification, multiple producers through > > multiple ports can enqueue to the event queues at a time.Does SW > > implementation > > support that? or am I missing something here? > > You're right that the IQ and QE rings are Single Producer, Single Consumer > rings. More specifically, the QE is a ring for sending rte_event structs > between cores, while the IQ ring is optimized for internal use in the > scheduler core - and should not be used to send events between cores. Note > that the design of the SW scheduler includes a central core for performing > scheduling.
Thanks Harry. One question though, In RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED mode, multiple SW schedulers can be active. Right? If so, We need multi consumer. Right? > > In other works, the QE rings transfer events from the worker core to the > scheduler - and the scheduler pushes the events into what you call the "event > queues" (aka, the atomic/ordered queue itself). These "event queues" are IQ > instances. On egress from the scheduler, the event passes through a QE ring > to the worker. > > The result is that despite that only SP/SC rings are used, multiple workers > can enqueue to any event queue. Got it.