From: Pavan Nikhilesh Date: Wed, 25 Oct 2017 14:50:28 +0000 (+0530) Subject: event/sw: extend service capability X-Git-Tag: spdx-start~1045 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=4c2fd9791db24f31b76aa187e212a6c8dd325fb0;p=dpdk.git event/sw: extend service capability Extend the service capability of the sw event device by exposing service id to the application. The application can use service id to configure service cores to run event scheduling. Signed-off-by: Pavan Nikhilesh Acked-by: Harry van Haaren --- diff --git a/drivers/event/sw/sw_evdev.c b/drivers/event/sw/sw_evdev.c index 522cd71aab..92fd07b7b9 100644 --- a/drivers/event/sw/sw_evdev.c +++ b/drivers/event/sw/sw_evdev.c @@ -861,6 +861,15 @@ sw_probe(struct rte_vdev_device *vdev) return -ENOEXEC; } + ret = rte_service_component_runstate_set(sw->service_id, 1); + if (ret) { + SW_LOG_ERR("Unable to enable service component"); + return -ENOEXEC; + } + + dev->data->service_inited = 1; + dev->data->service_id = sw->service_id; + return 0; }