| 1018 | } |
| 1019 | |
| 1020 | static int |
| 1021 | test_eventdev_unlink(void) |
| 1022 | { |
| 1023 | int ret, nb_queues, i; |
| 1024 | uint8_t queues[RTE_EVENT_MAX_QUEUES_PER_DEV]; |
| 1025 | |
| 1026 | ret = rte_event_port_unlink(TEST_DEV_ID, 0, NULL, 0); |
| 1027 | TEST_ASSERT(ret >= 0, "Failed to unlink with NULL device%d", |
| 1028 | TEST_DEV_ID); |
| 1029 | |
| 1030 | uint32_t queue_count; |
| 1031 | TEST_ASSERT_SUCCESS(rte_event_dev_attr_get(TEST_DEV_ID, |
| 1032 | RTE_EVENT_DEV_ATTR_QUEUE_COUNT, &queue_count), |
| 1033 | "Queue count get failed"); |
| 1034 | nb_queues = queue_count; |
| 1035 | for (i = 0; i < nb_queues; i++) |
| 1036 | queues[i] = i; |
| 1037 | |
| 1038 | ret = rte_event_port_link(TEST_DEV_ID, 0, NULL, NULL, 0); |
| 1039 | TEST_ASSERT(ret >= 0, "Failed to link with NULL device%d", |
| 1040 | TEST_DEV_ID); |
| 1041 | |
| 1042 | ret = rte_event_port_unlink(TEST_DEV_ID, 0, queues, nb_queues); |
| 1043 | TEST_ASSERT(ret == nb_queues, "Failed to unlink(device%d) ret=%d", |
| 1044 | TEST_DEV_ID, ret); |
| 1045 | return TEST_SUCCESS; |
| 1046 | } |
| 1047 | |
| 1048 | static int |
| 1049 | test_eventdev_link_get(void) |
nothing calls this directly
no test coverage detected