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

Function tun_clone_destroy

freebsd/net/if_tuntap.c:651–662  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

649}
650
651static int
652tun_clone_destroy(struct if_clone *ifc __unused, struct ifnet *ifp)
653{
654 struct tuntap_softc *tp = ifp->if_softc;
655
656 mtx_lock(&tunmtx);
657 TAILQ_REMOVE(&tunhead, tp, tun_list);
658 mtx_unlock(&tunmtx);
659 tun_destroy(tp);
660
661 return (0);
662}
663
664static void
665vnet_tun_init(const void *unused __unused)

Callers

nothing calls this directly

Calls 3

tun_destroyFunction · 0.85
mtx_lockFunction · 0.50
mtx_unlockFunction · 0.50

Tested by

no test coverage detected