From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jerin Jacob Subject: Re: [PATCH 2/5] eventdev: introduce specialized enqueue new op variant Date: Fri, 30 Jun 2017 14:41:57 +0530 Message-ID: <20170630091156.GA12111@jerin> References: <20170629141956.23132-1-jerin.jacob@caviumnetworks.com> <20170629141956.23132-2-jerin.jacob@caviumnetworks.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: "dev@dpdk.org" , "Richardson, Bruce" , "hemant.agrawal@nxp.com" , "Eads, Gage" , "nipun.gupta@nxp.com" , "Vangati, Narender" , "Rao, Nikhil" To: "Van Haaren, Harry" Return-path: Received: from NAM01-SN1-obe.outbound.protection.outlook.com (mail-sn1nam01on0043.outbound.protection.outlook.com [104.47.32.43]) by dpdk.org (Postfix) with ESMTP id C5CE6568A for ; Fri, 30 Jun 2017 11:12:15 +0200 (CEST) Content-Disposition: inline In-Reply-To: List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" -----Original Message----- > Date: Fri, 30 Jun 2017 08:40:06 +0000 > From: "Van Haaren, Harry" > To: Jerin Jacob , "dev@dpdk.org" > > CC: "Richardson, Bruce" , > "hemant.agrawal@nxp.com" , "Eads, Gage" > , "nipun.gupta@nxp.com" , > "Vangati, Narender" , "Rao, Nikhil" > > Subject: RE: [dpdk-dev] [PATCH 2/5] eventdev: introduce specialized enqueue > new op variant > > > From: Jerin Jacob [mailto:jerin.jacob@caviumnetworks.com] > > Sent: Thursday, June 29, 2017 3:20 PM > > To: dev@dpdk.org > > > diff --git a/drivers/event/octeontx/ssovf_evdev.c b/drivers/event/octeontx/ssovf_evdev.c > > index 8dc7b2ef8..0d0c6a186 100644 > > --- a/drivers/event/octeontx/ssovf_evdev.c > > +++ b/drivers/event/octeontx/ssovf_evdev.c > > @@ -158,6 +158,7 @@ ssovf_fastpath_fns_set(struct rte_eventdev *dev) > > dev->schedule = NULL; > > dev->enqueue = ssows_enq; > > dev->enqueue_burst = ssows_enq_burst; > > + dev->enqueue_new_burst = ssows_enq_burst; > > dev->dequeue = ssows_deq; > > dev->dequeue_burst = ssows_deq_burst; > > > > diff --git a/drivers/event/sw/sw_evdev.c b/drivers/event/sw/sw_evdev.c > > index fe2a61e2f..951ad1b33 100644 > > --- a/drivers/event/sw/sw_evdev.c > > +++ b/drivers/event/sw/sw_evdev.c > > @@ -796,6 +796,7 @@ sw_probe(struct rte_vdev_device *vdev) > > dev->dev_ops = &evdev_sw_ops; > > dev->enqueue = sw_event_enqueue; > > dev->enqueue_burst = sw_event_enqueue_burst; > > + dev->enqueue_new_burst = sw_event_enqueue_burst; > > dev->dequeue = sw_event_dequeue; > > dev->dequeue_burst = sw_event_dequeue_burst; > > dev->schedule = sw_event_schedule; > > > I think it is possible to do this pointer-setting of new_burst() in eventdev.c, instead of adding the new_burst() to each PMD individually? > During rte_eventdev_configure(), if the dev->enqueue_new_burst() function is NULL, just point it at the ordinary one; I thought so, But it will break in multi process use case as on probe() we are updating the callbacks for secondary process. Doing it in probe() may be very early as some PMD may update the callback anywhere on or before rte_eventdev_start(). Thoughts? > > if (!dev->enqueue_new_burst) > dev->enqueue_new_burst = dev->enqueue_burst; > > > This saves per-PMD changes for adding new parallel function pointers - and avoids PMDs accidentally not being updated. With that change; > > Acked-by: Harry van Haaren