From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id DF3A9324B for ; Tue, 19 Dec 2017 14:26:34 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 19 Dec 2017 05:26:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,426,1508828400"; d="scan'208";a="13905967" Received: from irsmsx154.ger.corp.intel.com ([163.33.192.96]) by fmsmga004.fm.intel.com with ESMTP; 19 Dec 2017 05:26:31 -0800 Received: from irsmsx112.ger.corp.intel.com (10.108.20.5) by IRSMSX154.ger.corp.intel.com (163.33.192.96) with Microsoft SMTP Server (TLS) id 14.3.319.2; Tue, 19 Dec 2017 13:26:30 +0000 Received: from irsmsx102.ger.corp.intel.com ([169.254.2.180]) by irsmsx112.ger.corp.intel.com ([169.254.1.12]) with mapi id 14.03.0319.002; Tue, 19 Dec 2017 13:26:30 +0000 From: "Van Haaren, Harry" To: Pavan Nikhilesh , "Eads, Gage" , "jerin.jacobkollanukkaran@cavium.com" , "Rao, Nikhil" , "hemant.agrawal@nxp.com" , "Ma, Liang J" CC: "dev@dpdk.org" Thread-Topic: [PATCH 06/13] examples/eventdev: add non burst mode generic worker Thread-Index: AQHTb5tvbu62BOPrYk6du1b19/Frt6NKmFKg Date: Tue, 19 Dec 2017 13:26:30 +0000 Message-ID: References: <20171207203705.25020-1-pbhagavatula@caviumnetworks.com> <20171207203705.25020-7-pbhagavatula@caviumnetworks.com> In-Reply-To: <20171207203705.25020-7-pbhagavatula@caviumnetworks.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiOWZjOTg5ZjktZWMxMy00MGZmLTgwY2UtMzJiZDE5YzMzNmZjIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE2LjUuOS4zIiwiVHJ1c3RlZExhYmVsSGFzaCI6IjI0VHJleG90QVhPMFowaTJwSnpJdU5raUh0V0tHcjRyU256b3B3SzBPaFU9In0= x-ctpclassification: CTP_IC dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [163.33.239.181] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH 06/13] examples/eventdev: add non burst mode generic worker X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 13:26:35 -0000 > From: Pavan Nikhilesh [mailto:pbhagavatula@caviumnetworks.com] > Sent: Thursday, December 7, 2017 8:37 PM > To: Eads, Gage ; jerin.jacobkollanukkaran@cavium.com= ; > Van Haaren, Harry ; Rao, Nikhil > ; hemant.agrawal@nxp.com; Ma, Liang J > > Cc: dev@dpdk.org; Pavan Nikhilesh > Subject: [PATCH 06/13] examples/eventdev: add non burst mode generic work= er >=20 > Currently, worker uses burst dequeue and burst enqueue to forward events. > Add a non burst mode based on the event dev capabilities. >=20 > Signed-off-by: Pavan Nikhilesh > diff --git a/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c > b/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c > index a72b7b2f9..5998aae95 100644 > --- a/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c > +++ b/examples/eventdev_pipeline_sw_pmd/pipeline_worker_generic.c > @@ -1,5 +1,91 @@ > +/* > + * BSD LICENSE > + * > + * Copyright 2016 Intel Corporation. > + * Copyright 2016 Cavium, Inc. > + * > + * Redistribution and use in source and binary forms, with or without > + * modification, are permitted provided that the following conditions > + * are met: > + * > + * * Redistributions of source code must retain the above copyright > + * notice, this list of conditions and the following disclaimer. > + * * Redistributions in binary form must reproduce the above copyrig= ht > + * notice, this list of conditions and the following disclaimer in > + * the documentation and/or other materials provided with the > + * distribution. > + * * Neither the name of Cavium, Inc nor the names of its > + * contributors may be used to endorse or promote products derived > + * from this software without specific prior written permission. > + * > + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS > + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT > + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS F= OR > + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGH= T > + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTA= L, > + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT > + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF US= E, > + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON A= NY > + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT > + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE U= SE > + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE= . > + */ > + Adding a license to an existing file? Also can now be updated to SPDX style > static __rte_always_inline int > consumer_burst(void) > { > @@ -412,9 +555,13 @@ generic_opt_check(void) > void > set_worker_generic_setup_data(struct setup_data *caps, bool burst) > { > - RTE_SET_USED(burst); > - caps->consumer_loop =3D consumer_burst; > - caps->worker_loop =3D worker_generic_burst; > + if (burst) { > + caps->consumer_loop =3D consumer_burst; > + caps->worker_loop =3D worker_generic_burst; > + } else { > + caps->consumer_loop =3D consumer; > + caps->worker_loop =3D worker_generic; > + } This won't scale well. See notes on future patch (9/13 and 10/13)