test/bonding: fix RSS test when disable RSS
[dpdk.git] / drivers / event / dpaa2 / dpaa2_eventdev_selftest.c
index b1f3891..b549bdf 100644 (file)
@@ -19,6 +19,7 @@
 #include <rte_random.h>
 #include <rte_bus_vdev.h>
 #include <rte_test.h>
+#include <rte_fslmc.h>
 
 #include "dpaa2_eventdev.h"
 #include "dpaa2_eventdev_logs.h"
@@ -47,17 +48,6 @@ struct event_attr {
        uint8_t seq;
 };
 
-static uint32_t seqn_list_index;
-static int seqn_list[NUM_PACKETS];
-
-static void
-seqn_list_init(void)
-{
-       RTE_BUILD_BUG_ON(NUM_PACKETS < MAX_EVENTS);
-       memset(seqn_list, 0, sizeof(seqn_list));
-       seqn_list_index = 0;
-}
-
 struct test_core_param {
        rte_atomic32_t *total_events;
        uint64_t dequeue_tmo_ticks;
@@ -128,7 +118,7 @@ _eventdev_setup(int mode)
        struct rte_event_dev_info info;
        const char *pool_name = "evdev_dpaa2_test_pool";
 
-       /* Create and destrory pool for each test case to make it standalone */
+       /* Create and destroy pool for each test case to make it standalone */
        eventdev_test_mempool = rte_pktmbuf_pool_create(pool_name,
                                        MAX_EVENTS,
                                        0 /*MBUF_CACHE_SIZE*/,
@@ -285,7 +275,8 @@ check_excess_events(uint8_t port)
                valid_event = rte_event_dequeue_burst(evdev, port, &ev, 1, 0);
 
                RTE_TEST_ASSERT_SUCCESS(valid_event,
-                               "Unexpected valid event=%d", ev.mbuf->seqn);
+                               "Unexpected valid event=%d",
+                               *dpaa2_seqn(ev.mbuf));
        }
        return 0;
 }
@@ -477,7 +468,7 @@ wait_workers_to_join(int lcore, const rte_atomic32_t *count)
        RTE_SET_USED(count);
 
        print_cycles = cycles = rte_get_timer_cycles();
-       while (rte_eal_get_lcore_state(lcore) != FINISHED) {
+       while (rte_eal_get_lcore_state(lcore) != WAIT) {
                uint64_t new_cycles = rte_get_timer_cycles();
 
                if (new_cycles - print_cycles > rte_get_timer_hz()) {
@@ -516,7 +507,7 @@ launch_workers_and_wait(int (*main_worker)(void *),
                return 0;
 
        rte_atomic32_set(&atomic_total_events, total_events);
-       seqn_list_init();
+       RTE_BUILD_BUG_ON(NUM_PACKETS < MAX_EVENTS);
 
        param = malloc(sizeof(struct test_core_param) * nb_workers);
        if (!param)