From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on0078.outbound.protection.outlook.com [104.47.36.78]) by dpdk.org (Postfix) with ESMTP id 77CA2101B for ; Tue, 21 Mar 2017 09:22:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Bj2VM6cLeh2UxTxCJC8ap5nKZ8I72mRD3HQhV8dv+Lw=; b=oXlP++CK/OmfevH3u7QgIMQTVuJ6I/Mp/hue1bBE0ZJlL6MKOvvI9lUThx3O07CX67IAnDYV4VFU5W5qQd7OYEOKmKQVTK6hRO9jcS9f3zvM1TEliBXIjg15DHA1Q4duVRR6MX/Si2AnpIbuBUnx40r9KXQPk0LqmGR35Z2yiIE= Authentication-Results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=caviumnetworks.com; Received: from localhost.localdomain (171.76.73.90) by BLUPR0701MB1716.namprd07.prod.outlook.com (10.163.85.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.977.11; Tue, 21 Mar 2017 08:22:00 +0000 Date: Tue, 21 Mar 2017 13:51:47 +0530 From: Jerin Jacob To: Harry van Haaren Cc: dev@dpdk.org Message-ID: <20170321082145.qgj5c76ebe5fcxcu@localhost.localdomain> References: <1488372542-156763-1-git-send-email-harry.van.haaren@intel.com> <1489159155-80489-1-git-send-email-harry.van.haaren@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1489159155-80489-1-git-send-email-harry.van.haaren@intel.com> User-Agent: NeoMutt/20170306 (1.8.0) X-Originating-IP: [171.76.73.90] X-ClientProxiedBy: PN1PR01CA0010.INDPRD01.PROD.OUTLOOK.COM (10.164.137.17) To BLUPR0701MB1716.namprd07.prod.outlook.com (10.163.85.142) X-MS-Office365-Filtering-Correlation-Id: 3587fc92-718d-474e-dc0b-08d4703359f1 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:BLUPR0701MB1716; X-Microsoft-Exchange-Diagnostics: 1; BLUPR0701MB1716; 3:vT4Kwwm9QKpeF9EcbZnx9Cif9u4otLQHkyV4eqeYGRI+9XYPuwuxBK9hRUF9TgpXXgX4cNPr0QHRY1TQQ7B7TiAutZNSj/gxS4IPm5nMtd4rs/TBnFyv4u2o3QjCneMlLDJeITxa8VUlPVvQdRUIJ3MEMrjFinvOGsn9igZuNJrAjWCeNzuD090KkAH4dFZQgglDPoOwvj3t473G0KgLX04uaEwZTQAYTuMY2gISyOClNDaA7lXVsANf6dYx9tidq8xq6Lvz8xmYhUujzqXyqw==; 25:IMeyr/CXQEAZFkV782H8A78hjNUuiaOkHOc6r6rTwIEGxTIm1jJWUU8besB7R8EDpwRdtkfAQFzbov+CpT7khdf2nhnR+NFhy2u38EYtmgia2PNWaIbIEyUi8iVoSktL3wk2vU+rj63plyGLeFIwNXVGQ7FzDt2hR0nVBVh/Qfvg7wwLTorqs+iK/rx7+2rQJXc02Y8LWLwQElchlYPv1NJjMUc0gcJUiH6R8aepMMyHLxutSuck09pQ9I7/A8K+pnq7VQRHqFv51XoT7r/Qm3OUT2op0qmbK77cu3JCPONZ2/Y13RPZBa+MoR/PmGBcVTPPWk72zrqQOhd30eNLXO7sJz6RWNRcO00k0bJByoIe/ND6+as+JN3WATJyE/IyRvSwy+XFfHe3ccCrS+JWRLiQ2mAyu/I6FHjZNwIush4al3ub9bByJqwAdypahBDOuh4lh+q+iC/WNp2qNnXPFg== X-Microsoft-Exchange-Diagnostics: 1; BLUPR0701MB1716; 31:trzxPr0InFMGBE8TZXdtIamiUAGYZD/vEpy4y1NY6s5LmWF3CgZBbFdBV9+XXXzABHF8GOQj+s1MF8M4LolADne66FmhzV3cYYvPcPpUxFif2L6qHMtcAmF58KoV2Pa68T9LrpluTGKl+3HSSH+3DaSU3Jr8Hsu1xXix9WkjN6OLD3829tDshkWUoi84GJyWQaGHM90gm5kcSJaj7p5PmclfQbQfRH0IzOL89i3DBtqwTFwHF8VKMpP5+sewoTY1ZyxuJuzqIy5kIrXyo5KYig==; 20:xqOnOwfJXLSlliUTo9uXm73oGtPVAgM36PaAZJCi4m7xteEZVGNuLatwixmQZzRzJTzYXT9Wa0G6sMnzx+MRLHenTw/bDklXhOufP1HYU8aIbXvfmmI6q5pjG3UXMTS7BDAhBL1VBod7diPzGn0bCWQ5QSH+5hmono7f/CNxapiGHtnxkdhkrOTj6KXJq+jigER0FGqqvr2B7UcDYmnZOD8eI4wejfPRzpoLlNOG2TvF32dpqu2r00oCYn6BOf2NECoprlaAAVB0OnbwUZiagbjxHoUAgM86dqqqHvWOd3vZijqOOl4p41rHQ7KhPLaVRp2W+pK4XVCk4Q3iPONaNlu8j0mXDVh6BVFHwKnOfnpSph9prM1l0mtgDI6t8Vz0QDODvTuIa1blAycGKpmWib/B0gfICICJtgRpTXy6qOpnUPv7tHtKhVI/f83m2SA3Dqgp6Xr77V3y4JewHLXCjvs+tU0o00wMNnmDVUb7CY/So38JJV+w334aXRjBX8o5Vh0L4XtN9BpKDSJHDpjMIQGJf/ZdHm8+9FqFa1JKqVt6CAC7mvAZGRSUCxT48KBASGabK4J1FZ66hv8CgbcHNApselu5D0o7IpY5kNmkzgM= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(278428928389397)(228905959029699); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046)(6041248)(20161123564025)(20161123555025)(20161123558025)(20161123562025)(20161123560025)(6072148); SRVR:BLUPR0701MB1716; BCL:0; PCL:0; RULEID:; SRVR:BLUPR0701MB1716; X-Microsoft-Exchange-Diagnostics: 1; BLUPR0701MB1716; 4:q58e0tDDVJl1TcTqU7DNExDYTRwtK3/xk6b26KiUTxSDyzEoJqPc1h2tE1fiKPPLWffCOG5neeurSiOfYlARUXBDrLJsySHnXwRtpY2+lxYcHAwn76rp8wHE9V3loTZZFJRuplXCeHAMgYliYEvL1pRcsd+rIXc4frhnsRflLOBQIp5BlQKbKz6sgo66Stk2N7wQTQk3zh0bdxGvmdzh6J+QEFe2MGtG7QnsOvAtyV2KnZZ3lwoHmu35Ad8MZA6RAmAdPyFv8U/7bxYbVA9OEJomGjzrUHAdc0x8axBsc8a7Y25fugK85/l9XJFcnwfB2Q1S8eSb7cD624Qlp6NBIrHvDoBPXja0aOHdbroLPzQjH9ppKmKlpFPCHQ/1uoSDQ5ih8xZGsz8bTjnSCrW+W1mXkjtA/e9l2nh5U9FAOOA3b7X+YoPZqqIy7f4nrspdK6X7paG/f2Pilj/lLhsnPNAGrWd1KyclKGUe/o9Hh3ev4Flzn6vwk+J1gYHjyC1+Jtcs+Yc9peWruiVQiJlruoG5/KZN4DKn/6n9w6Wy/jXo2BZTIAFBqIdDJmQjCBW+/hNmDTz9QyqCLG0H3/JeeDrAVw/YL/R2/lCsdaxTMAXklVzCF7XcJ79EdQyPZhGsvM3YFcnc0CJ3Mu2FD4hHio5FpbO8YU/JtvroGB4zdwXTwP6QKfY5IXi5Zw/PTImD X-Forefront-PRVS: 02530BD3AA X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6069001)(6009001)(39830400002)(39450400003)(24454002)(9686003)(53936002)(3846002)(6116002)(305945005)(7736002)(81166006)(38730400002)(189998001)(110136004)(8676002)(47776003)(6246003)(55016002)(66066001)(23726003)(4326008)(575784001)(2906002)(4001350100001)(42882006)(25786008)(42186005)(2950100002)(6666003)(54356999)(6506006)(50986999)(6916009)(5660300001)(76176999)(33646002)(50466002)(229853002)(1076002); DIR:OUT; SFP:1101; SCL:1; SRVR:BLUPR0701MB1716; H:localhost.localdomain; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BLUPR0701MB1716; 23:S/8tPIr64sGiF3uoTnX4Vi6QZzWygnI23qGZEWj?= =?us-ascii?Q?KuQoighq98NEiIoD3h9vVxtT5dZKRFRoogD/a5o28wqGP82X9osXTTi7KMn2?= =?us-ascii?Q?6+3zZANWai4kIrnu3q/63DFgGME7I9ZzmZREXVOSBJZFVb5gRl85wLBLWQRn?= =?us-ascii?Q?PNKOvIDuGtgUBNOFZ8zLq7S5rGwmZENvcah6Tn8PadJmDA/bKiouWEdGnw4M?= =?us-ascii?Q?CXs16LXcvOsiL2gL4DaLycNY6ghDImoTIGfdIsW1D0g1qOpBk20rLN0QFh1K?= =?us-ascii?Q?PXHca3mnY4THopQIA5rGsc1+vhAVSPXi5Enht6xzfOIlFoE1zGrU6fYYuoVj?= =?us-ascii?Q?spu7pkVkM71eTIfzBER12BvWRyR94NxDCErurmQ2++rULodiGx/DK0P5ON3L?= =?us-ascii?Q?FNyge3wBh2O9HiKg8vVZ+Kt2yBmUrQt7CyXDs3D77gm8dvSZ7287ussr9F8z?= =?us-ascii?Q?6ZmjfPqFPGBM3pQtK/bsHXC1U/9sQ0wI4fTeA6ZXBa3zum9xMoodwGHgwTkG?= =?us-ascii?Q?ci6OsesOkyr2IJIuUqqhcp9cafnO4mpt6WQbGABRUQs5YuRYba5JggPQ54Z9?= =?us-ascii?Q?qKii4UIoh1N4+VgZvYTrX0IndHmvs6wRtOLT0QkUMTtAJleEv7+Xs5Rllr1J?= =?us-ascii?Q?y8fMzcECvfjKPyNEZBC+6Fb4973e52n/V7BWUyNVxBzJUv2e+gpT25cP+d26?= =?us-ascii?Q?xAIzUcd10EtdpXg0NEkRSiRyF7+1CyxuGH639kFt+FDd7h5YHZ079DkUP8qt?= =?us-ascii?Q?xVV2uiYD6SfcSvhV9Nep4BT5BQVhyxLBikJr694G+HzN1Hja3NzQ+CaB70B3?= =?us-ascii?Q?mr4z3lXVcUqLLoIiZHykukHHQhOYm82BB+UdNGQ/aSgvrZexAleNW5yUXHXK?= =?us-ascii?Q?G6C5MUmT1XzqC8DRCc8tymgydQf7OufEiqzL/uIbzhRPm2VXB8rVkP+TaIQG?= =?us-ascii?Q?UX3nxPJmka9NYcxJGsGkEI7ZRfxf0fSR1FYKwdS9YI+f3RFHS0cghuuCT4ta?= =?us-ascii?Q?C96x/gKxUe4Lcfle1w59nR7Ag5J+6eEY8tqFpYBeu4m1Nzw=3D=3D?= X-Microsoft-Exchange-Diagnostics: 1; BLUPR0701MB1716; 6:Qs4Gf/BmGHH8Sz6rhkGpS/eTLrfAnPAdCYq8Rbr8rWTYvbzY62d4azIT3djGvbPpuLpYKBKfIrQmQIrcP7Srj3zXuJkvARibv8h/yj2aDz6I+xOFcRt6W8NAlbMNEvDoqJhivqpEKLMAI27ZFZyMnyvC81brlSuFIEQ1C3+Q6PyuZbPFdpozWW5+UohkCaQOYYne7Y5hTdy/wxNPPkdQf8cocubSZap8okkJnIzi2KyaircpuZWr5kBk0rN38d2bmksjZC034zE6SPeE3SDuIBcSQ39fUtotLcqeWDLhFx6irrpCAvc3HREU/hBKQB4LCIaLVdslIWEYDei0GE0/Gf/29pK3l5eJjd4s02cOh73A3tasbC17Ihua/kWGoaUrDj/auZrpyLOywv1Kco4SIA==; 5:TPmJTpGQ0HrOswJZlVBsms9l1RUpK3eMlaPvXQ1iiw/2M667SwIq0kDPl3peUPx77AlxDbxxL4kOHNIvpA4DoPgqs9+FVM2IwkawCSl/DhQC8BxWNS90e+BFMTYP4f9nwCYLr4CgKzdvHj4dtiEU5w==; 24:9r5G8ggl7Vr3vr4RDcUwtFqSRQYdpkhvnelZms16VK45+5taQiTmOVt7rpEmbMRqlBLnfYCHEnxlLLAoDlBEtAAJN8pl/QI64O2jR6dvZ8c= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BLUPR0701MB1716; 7:+Vb76MGx/MI1UKOHYb565fAZEbPUJzODBo6lxuuqp2LiZKzAm3X0O0OEdl/9tvFbQhb+2FDc8bg62opw5A//KFN/+9bQV6daN7dCUtB5CE6KUu0YYWHmmLjRV25rAk8KUkeb5GjfG4Hwi6dMgv44gaba+e7BVufkO3tiIMAu8aQzcLDVa8HHRYZhx+DIzYU3gQwOnV3+NuGMoGzprtHHDSEKkICEVACc2rtODDuuJaQmM7GihrLANK1rQV3JyOJAwoX04fDNGDJyDqKeCjQz+2ZwqxdCAXhCj1qOQK3VIHUE2+xxrCnG8CvtqkY5hC/JPt8Ro8NUy0RgHcUPsU09GA== X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Mar 2017 08:22:00.8166 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR0701MB1716 Subject: Re: [dpdk-dev] [PATCH v2] eventdev: remove default queue overriding 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, 21 Mar 2017 08:22:05 -0000 On Fri, Mar 10, 2017 at 03:19:15PM +0000, Harry van Haaren wrote: > PMDs that only do a specific type of scheduling cannot provide > CFG_ALL_TYPES, so the Eventdev infrastructure should not demand > that every PMD supports CFG_ALL_TYPES. > > By not overriding the default configuration of the queue as > suggested by the PMD, the eventdev_common unit tests can pass > on all PMDs, regardless of their capabilities. > > RTE_EVENT_QUEUE_CFG_DEFAULT is no longer used by the eventdev layer > it can be removed now. Applications should use CFG_ALL_TYPES > if they require enqueue of all types a queue, or specify which > type of queue they require. > > The CFG_DEFAULT value is changed to CFG_ALL_TYPES in event/skeleton, > to not break the compile. > > A capability flag is added that indicates if the underlying PMD > supports creating queues of ALL_TYPES. > > Signed-off-by: Harry van Haaren I think It is reasonable to have this capability if SW PMD can not support it for performance reasons. The only downside is, In application side there will be changes in the fast path.I think, The reasonable trade-off between performance and portability to keep packet processing functions as common and keep the pipeline advancement logic as different main loop based on capability. Two reasons why CFG_ALL_TYPES important for HW - Event queue is the precious resource and it is very limited and it consumes power and internal resources like SRAM - The use case like flow based event pipelining will not have constraint on which event queues it enqueues to I think We can add this capability flag now and once we have performance and latency test cases for eventdev then we can check is there any scope for improvement in SW PMD.With that note, Acked-by: Jerin Jacob > > --- > > v2: > - added capability flag to indicate if PMD supports ALL_TYPES > > --- > drivers/event/skeleton/skeleton_eventdev.c | 2 +- > lib/librte_eventdev/rte_eventdev.c | 1 - > lib/librte_eventdev/rte_eventdev.h | 13 +++++++------ > 3 files changed, 8 insertions(+), 8 deletions(-) > > diff --git a/drivers/event/skeleton/skeleton_eventdev.c b/drivers/event/skeleton/skeleton_eventdev.c > index dee0faf..308e28e 100644 > --- a/drivers/event/skeleton/skeleton_eventdev.c > +++ b/drivers/event/skeleton/skeleton_eventdev.c > @@ -196,7 +196,7 @@ skeleton_eventdev_queue_def_conf(struct rte_eventdev *dev, uint8_t queue_id, > > queue_conf->nb_atomic_flows = (1ULL << 20); > queue_conf->nb_atomic_order_sequences = (1ULL << 20); > - queue_conf->event_queue_cfg = RTE_EVENT_QUEUE_CFG_DEFAULT; > + queue_conf->event_queue_cfg = RTE_EVENT_QUEUE_CFG_ALL_TYPES; > queue_conf->priority = RTE_EVENT_DEV_PRIORITY_NORMAL; > } > > diff --git a/lib/librte_eventdev/rte_eventdev.c b/lib/librte_eventdev/rte_eventdev.c > index 68bfc3b..c32a776 100644 > --- a/lib/librte_eventdev/rte_eventdev.c > +++ b/lib/librte_eventdev/rte_eventdev.c > @@ -593,7 +593,6 @@ rte_event_queue_setup(uint8_t dev_id, uint8_t queue_id, > RTE_FUNC_PTR_OR_ERR_RET(*dev->dev_ops->queue_def_conf, > -ENOTSUP); > (*dev->dev_ops->queue_def_conf)(dev, queue_id, &def_conf); > - def_conf.event_queue_cfg = RTE_EVENT_QUEUE_CFG_DEFAULT; > queue_conf = &def_conf; > } > > diff --git a/lib/librte_eventdev/rte_eventdev.h b/lib/librte_eventdev/rte_eventdev.h > index 7073987..4c73a82 100644 > --- a/lib/librte_eventdev/rte_eventdev.h > +++ b/lib/librte_eventdev/rte_eventdev.h > @@ -271,6 +271,13 @@ struct rte_mbuf; /* we just use mbuf pointers; no need to include rte_mbuf.h */ > * > * @see rte_event_schedule(), rte_event_dequeue_burst() > */ > +#define RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES (1ULL << 3) > +/**< Event device is capable of enqueuing events of any type to any queue. > + * If this capability is not set, the queue only supports events of the > + * *RTE_EVENT_QUEUE_CFG_* type that it was created with. > + * > + * @see RTE_EVENT_QUEUE_CFG_* values > + */ > > /* Event device priority levels */ > #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0 > @@ -471,12 +478,6 @@ rte_event_dev_configure(uint8_t dev_id, > /* Event queue specific APIs */ > > /* Event queue configuration bitmap flags */ > -#define RTE_EVENT_QUEUE_CFG_DEFAULT (0) > -/**< Default value of *event_queue_cfg* when rte_event_queue_setup() invoked > - * with queue_conf == NULL > - * > - * @see rte_event_queue_setup() > - */ > #define RTE_EVENT_QUEUE_CFG_TYPE_MASK (3ULL << 0) > /**< Mask for event queue schedule type configuration request */ > #define RTE_EVENT_QUEUE_CFG_ALL_TYPES (0ULL << 0) > -- > 2.7.4 >