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

Function stf_clone_destroy

freebsd/net/if_stf.c:267–283  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

265}
266
267static int
268stf_clone_destroy(struct if_clone *ifc, struct ifnet *ifp)
269{
270 struct stf_softc *sc = ifp->if_softc;
271 int err __unused;
272
273 err = ip_encap_detach(sc->encap_cookie);
274 KASSERT(err == 0, ("Unexpected error detaching encap_cookie"));
275 bpfdetach(ifp);
276 if_detach(ifp);
277 if_free(ifp);
278
279 free(sc, M_STF);
280 ifc_free_unit(ifc, STFUNIT);
281
282 return (0);
283}
284
285static int
286stfmodevent(module_t mod, int type, void *data)

Callers

nothing calls this directly

Calls 6

ip_encap_detachFunction · 0.85
bpfdetachFunction · 0.85
if_detachFunction · 0.85
if_freeFunction · 0.85
ifc_free_unitFunction · 0.85
freeFunction · 0.50

Tested by

no test coverage detected