MCPcopy Create free account
hub / github.com/F-Stack/f-stack / do_recursive_call

Function do_recursive_call

dpdk/app/test/test.c:57–100  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55no_action(void){ return 0; }
56
57static int
58do_recursive_call(void)
59{
60 unsigned i;
61 struct {
62 const char *env_var;
63 int (*action_fn)(void);
64 } actions[] = {
65#ifndef RTE_EXEC_ENV_WINDOWS
66 { "run_secondary_instances", test_mp_secondary },
67#endif
68#ifdef RTE_LIB_PDUMP
69#ifdef RTE_NET_RING
70 { "run_pdump_server_tests", test_pdump },
71#endif
72#endif
73 { "test_missing_c_flag", no_action },
74 { "test_main_lcore_flag", no_action },
75 { "test_invalid_n_flag", no_action },
76 { "test_no_hpet_flag", no_action },
77 { "test_allow_flag", no_action },
78 { "test_invalid_b_flag", no_action },
79 { "test_invalid_vdev_flag", no_action },
80 { "test_invalid_r_flag", no_action },
81 { "test_misc_flags", no_action },
82 { "test_memory_flags", no_action },
83 { "test_file_prefix", no_action },
84 { "test_no_huge_flag", no_action },
85#ifdef RTE_LIB_TIMER
86#ifndef RTE_EXEC_ENV_WINDOWS
87 { "timer_secondary_spawn_wait", test_timer_secondary },
88#endif
89#endif
90 };
91
92 if (recursive_call == NULL)
93 return -1;
94 for (i = 0; i < RTE_DIM(actions); i++) {
95 if (strcmp(actions[i].env_var, recursive_call) == 0)
96 return (actions[i].action_fn)();
97 }
98 printf("ERROR - missing action to take for %s\n", recursive_call);
99 return -1;
100}
101
102int last_test_result;
103

Callers 1

mainFunction · 0.85

Calls 2

strcmpFunction · 0.85
printfFunction · 0.50

Tested by

no test coverage detected