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

Function cmd_dump_one_parsed

dpdk/app/test/commands.c:168–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

166};
167
168static void cmd_dump_one_parsed(void *parsed_result, struct cmdline *cl,
169 __rte_unused void *data)
170{
171 struct cmd_dump_one_result *res = parsed_result;
172
173 if (!strcmp(res->dump, "dump_ring")) {
174 struct rte_ring *r;
175 r = rte_ring_lookup(res->name);
176 if (r == NULL) {
177 cmdline_printf(cl, "Cannot find ring\n");
178 return;
179 }
180 rte_ring_dump(stdout, r);
181 }
182 else if (!strcmp(res->dump, "dump_mempool")) {
183 struct rte_mempool *mp;
184 mp = rte_mempool_lookup(res->name);
185 if (mp == NULL) {
186 cmdline_printf(cl, "Cannot find mempool\n");
187 return;
188 }
189 rte_mempool_dump(stdout, mp);
190 }
191}
192
193cmdline_parse_token_string_t cmd_dump_one_dump =
194 TOKEN_STRING_INITIALIZER(struct cmd_dump_one_result, dump,

Callers

nothing calls this directly

Calls 6

strcmpFunction · 0.85
rte_ring_lookupFunction · 0.85
cmdline_printfFunction · 0.85
rte_ring_dumpFunction · 0.85
rte_mempool_lookupFunction · 0.85
rte_mempool_dumpFunction · 0.85

Tested by

no test coverage detected