From: Harry van Haaren Date: Fri, 10 Mar 2017 19:43:17 +0000 (+0000) Subject: test/eventdev: link all queues before start X-Git-Tag: spdx-start~3855 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=1d8db7d087bd2acba8559a930c964be27748b51a;p=dpdk.git test/eventdev: link all queues before start The software eventdev can lock-up if not all queues are linked to a port. For this reason, the software evendev fails to start if queues are not linked to anything. This commit creates dummy links from all queues to port 0 in the eventdev setup function and start/stop test, which would otherwise fail due to unlinked queues. Signed-off-by: Harry van Haaren Acked-by: Jerin Jacob --- diff --git a/test/test/test_eventdev.c b/test/test/test_eventdev.c index e087af2fc8..0f1deb6a98 100644 --- a/test/test/test_eventdev.c +++ b/test/test/test_eventdev.c @@ -543,6 +543,10 @@ test_eventdev_start_stop(void) TEST_ASSERT_SUCCESS(ret, "Failed to setup port%d", i); } + ret = rte_event_port_link(TEST_DEV_ID, 0, NULL, NULL, 0); + TEST_ASSERT(ret == rte_event_queue_count(TEST_DEV_ID), + "Failed to link port, device %d", TEST_DEV_ID); + ret = rte_event_dev_start(TEST_DEV_ID); TEST_ASSERT_SUCCESS(ret, "Failed to start device%d", TEST_DEV_ID); @@ -569,6 +573,10 @@ eventdev_setup_device(void) TEST_ASSERT_SUCCESS(ret, "Failed to setup port%d", i); } + ret = rte_event_port_link(TEST_DEV_ID, 0, NULL, NULL, 0); + TEST_ASSERT(ret == rte_event_queue_count(TEST_DEV_ID), + "Failed to link port, device %d", TEST_DEV_ID); + ret = rte_event_dev_start(TEST_DEV_ID); TEST_ASSERT_SUCCESS(ret, "Failed to start device%d", TEST_DEV_ID);