rte_timer_subsystem_init() may return -EALREADY if the timer subsystem
was already initialized. This can happen i.e. in PMD code (see
eth_ena_dev_init). This is not an error, rather a notification as the
initialization function simply returns without any action taken.
Fixes:
50247fe03fe0 ("test/timer: exercise new APIs in secondary process")
Cc: stable@dpdk.org
Signed-off-by: Stanislaw Kardach <kda@semihalf.com>
Reviewed-by: Michal Krawczyk <mk@semihalf.com>
goto out;
}
+ argv += ret;
+
+ prgname = argv[0];
+
#ifdef RTE_LIB_TIMER
- if (rte_timer_subsystem_init() < 0) {
+ ret = rte_timer_subsystem_init();
+ if (ret < 0 && ret != -EALREADY) {
ret = -1;
goto out;
}
goto out;
}
- argv += ret;
-
- prgname = argv[0];
-
recursive_call = getenv(RECURSIVE_ENV_VAR);
if (recursive_call != NULL) {
ret = do_recursive_call();