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

Function rte_fib6_free

dpdk/lib/fib/rte_fib6.c:281–308  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

279}
280
281void
282rte_fib6_free(struct rte_fib6 *fib)
283{
284 struct rte_tailq_entry *te;
285 struct rte_fib6_list *fib_list;
286
287 if (fib == NULL)
288 return;
289
290 fib_list = RTE_TAILQ_CAST(rte_fib6_tailq.head, rte_fib6_list);
291
292 rte_mcfg_tailq_write_lock();
293
294 /* find our tailq entry */
295 TAILQ_FOREACH(te, fib_list, next) {
296 if (te->data == (void *)fib)
297 break;
298 }
299 if (te != NULL)
300 TAILQ_REMOVE(fib_list, te, next);
301
302 rte_mcfg_tailq_write_unlock();
303
304 free_dataplane(fib);
305 rte_rib6_free(fib->rib);
306 rte_free(fib);
307 rte_free(te);
308}
309
310void *
311rte_fib6_get_dp(struct rte_fib6 *fib)

Callers 5

test_fib6_perfFunction · 0.85
test_multiple_createFunction · 0.85
test_free_nullFunction · 0.85
test_add_del_invalidFunction · 0.85
test_lookupFunction · 0.85

Calls 5

rte_rib6_freeFunction · 0.85
rte_freeFunction · 0.85
free_dataplaneFunction · 0.70

Tested by 5

test_fib6_perfFunction · 0.68
test_multiple_createFunction · 0.68
test_free_nullFunction · 0.68
test_add_del_invalidFunction · 0.68
test_lookupFunction · 0.68