event/dpaa2: return correct number of event ports
authorNipun Gupta <nipun.gupta@nxp.com>
Wed, 3 Jan 2018 16:44:19 +0000 (22:14 +0530)
committerJerin Jacob <jerin.jacob@caviumnetworks.com>
Fri, 19 Jan 2018 15:09:56 +0000 (16:09 +0100)
In the info get API we were returning number of event
ports as MAX number of LCORE's. After this change actual
number of event ports (i.e. number of DPIO's) is provided
in the info get API.

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
drivers/event/dpaa2/dpaa2_eventdev.c

index 88dd930..1d3e361 100644 (file)
@@ -304,7 +304,7 @@ dpaa2_eventdev_info_get(struct rte_eventdev *dev,
                DPAA2_EVENT_MAX_QUEUE_PRIORITY_LEVELS;
        dev_info->max_event_priority_levels =
                DPAA2_EVENT_MAX_EVENT_PRIORITY_LEVELS;
-       dev_info->max_event_ports = RTE_MAX_LCORE;
+       dev_info->max_event_ports = rte_fslmc_get_device_count(DPAA2_IO);
        dev_info->max_event_port_dequeue_depth =
                DPAA2_EVENT_MAX_PORT_DEQUEUE_DEPTH;
        dev_info->max_event_port_enqueue_depth =