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

Function graph_mem_fixup_node_ctx

dpdk/lib/graph/graph.c:263–292  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

261}
262
263static struct rte_graph *
264graph_mem_fixup_node_ctx(struct rte_graph *graph)
265{
266 struct rte_node *node;
267 struct node *node_db;
268 rte_graph_off_t off;
269 rte_node_t count;
270 const char *name;
271
272 rte_graph_foreach_node(count, off, graph, node) {
273 if (node->parent_id == RTE_NODE_ID_INVALID) /* Static node */
274 name = node->name;
275 else /* Cloned node */
276 name = node->parent;
277
278 node_db = node_from_name(name);
279 if (node_db == NULL)
280 SET_ERR_JMP(ENOLINK, fail, "Node %s not found", name);
281
282 if (graph->pcap_enable) {
283 node->process = graph_pcap_dispatch;
284 node->original_process = node_db->process;
285 } else
286 node->process = node_db->process;
287 }
288
289 return graph;
290fail:
291 return NULL;
292}
293
294static struct rte_graph *
295graph_mem_fixup_secondary(struct rte_graph *graph)

Callers 1

Calls 1

node_from_nameFunction · 0.85

Tested by

no test coverage detected