summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMattias Rönnblom <mattias.ronnblom@ericsson.com>2019-05-10 14:18:16 +0200
committerThomas Monjalon <thomas@monjalon.net>2019-05-13 16:19:05 +0200
commit7e192bdb0c55745a81e7f5e0eaf2b7a911aeadd4 (patch)
treef805d8f64d4410bab968955cf96a2e36a1118516
parent339677f87023ccfa8d96b88dd4469a0dc25f813d (diff)
downloaddpdk-draft-windows-7e192bdb0c55745a81e7f5e0eaf2b7a911aeadd4.zip
dpdk-draft-windows-7e192bdb0c55745a81e7f5e0eaf2b7a911aeadd4.tar.gz
dpdk-draft-windows-7e192bdb0c55745a81e7f5e0eaf2b7a911aeadd4.tar.xz
event/dsw: ignore scheduling type for single-link queues
The scheduling type parameter is not applicable for single link queues. DSW would, at the time of rte_event_queue_setup(), erroneously verify that scheduling type was one of the supported types, and returned -ENOTSUP in case of RTE_SCHED_TYPE_ORDERED. Fixes: 4540ee9c68 ("event/dsw: add device and queue configuration") Cc: stable@dpdk.org Signed-off-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com> Acked-by: Gage Eads <gage.eads@intel.com>
-rw-r--r--drivers/event/dsw/dsw_evdev.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/event/dsw/dsw_evdev.c b/drivers/event/dsw/dsw_evdev.c
index 4157d13..9387d41 100644
--- a/drivers/event/dsw/dsw_evdev.c
+++ b/drivers/event/dsw/dsw_evdev.c
@@ -102,9 +102,6 @@ dsw_queue_setup(struct rte_eventdev *dev, uint8_t queue_id,
if (RTE_EVENT_QUEUE_CFG_ALL_TYPES & conf->event_queue_cfg)
return -ENOTSUP;
- if (conf->schedule_type == RTE_SCHED_TYPE_ORDERED)
- return -ENOTSUP;
-
/* SINGLE_LINK is better off treated as TYPE_ATOMIC, since it
* avoid the "fake" TYPE_PARALLEL flow_id assignment. Since
* the queue will only have a single serving port, no
@@ -113,8 +110,12 @@ dsw_queue_setup(struct rte_eventdev *dev, uint8_t queue_id,
*/
if (RTE_EVENT_QUEUE_CFG_SINGLE_LINK & conf->event_queue_cfg)
queue->schedule_type = RTE_SCHED_TYPE_ATOMIC;
- else /* atomic or parallel */
+ else {
+ if (conf->schedule_type == RTE_SCHED_TYPE_ORDERED)
+ return -ENOTSUP;
+ /* atomic or parallel */
queue->schedule_type = conf->schedule_type;
+ }
queue->num_serving_ports = 0;