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

Function vlan_freehash

freebsd/net/if_vlan.c:364–378  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

362}
363
364static void
365vlan_freehash(struct ifvlantrunk *trunk)
366{
367#ifdef INVARIANTS
368 int i;
369
370 KASSERT(trunk->hwidth > 0, ("%s: hwidth not positive", __func__));
371 for (i = 0; i < (1 << trunk->hwidth); i++)
372 KASSERT(CK_SLIST_EMPTY(&trunk->hash[i]),
373 ("%s: hash table not empty", __func__));
374#endif
375 free(trunk->hash, M_VLAN);
376 trunk->hash = NULL;
377 trunk->hwidth = trunk->hmask = 0;
378}
379
380static int
381vlan_inshash(struct ifvlantrunk *trunk, struct ifvlan *ifv)

Callers 1

trunk_destroyFunction · 0.85

Calls 1

freeFunction · 0.50

Tested by

no test coverage detected