app/testpmd: block secondary process
authorStephen Hemminger <stephen@networkplumber.org>
Fri, 2 Aug 2019 02:51:53 +0000 (19:51 -0700)
committerThomas Monjalon <thomas@monjalon.net>
Mon, 5 Aug 2019 13:47:51 +0000 (15:47 +0200)
Since testpmd has several issues which keep it from working correctly
as a secondary process; abort if user tries to do it, rather than
running into later problems.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
app/test-pmd/testpmd.c

index 159c2ef..d0142ca 100644 (file)
@@ -3243,6 +3243,9 @@ main(int argc, char** argv)
        if (diag < 0)
                rte_panic("Cannot init EAL\n");
 
+       if (rte_eal_process_type() == RTE_PROC_SECONDARY)
+               rte_panic("Secondary process type not supported.\n");
+
        ret = register_eth_event_callback();
        if (ret != 0)
                rte_panic("Cannot register for ethdev events");