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

Function if_ref

freebsd/net/if.c:738–744  ·  view source on GitHub ↗

* Interfaces to keep an ifnet type-stable despite the possibility of the * driver calling if_free(). If there are additional references, we defer * freeing the underlying data structure. */

Source from the content-addressed store, hash-verified

736 * freeing the underlying data structure.
737 */
738void
739if_ref(struct ifnet *ifp)
740{
741
742 /* We don't assert the ifnet list lock here, but arguably should. */
743 refcount_acquire(&ifp->if_refcount);
744}
745
746void
747if_rele(struct ifnet *ifp)

Callers 15

pfi_attach_ifnetFunction · 0.85
ifaddr_cbFunction · 0.85
carp_alloc_ifFunction · 0.85
inm_disconnectFunction · 0.85
inp_lookup_mcast_ifpFunction · 0.85
in6m_disconnect_lockedFunction · 0.85
m_snd_tag_initFunction · 0.85
ktls_alloc_snd_tagFunction · 0.85
ifnet_byindex_refFunction · 0.85
ifunit_refFunction · 0.85
vxlan_multicast_if_refFunction · 0.85
rt_exportinfoFunction · 0.85

Calls 1

refcount_acquireFunction · 0.85

Tested by

no test coverage detected