Changeset View
Changeset View
Standalone View
Standalone View
sys/kern/kern_mbuf.c
Show First 20 Lines • Show All 1,629 Lines • ▼ Show 20 Lines | m_snd_tag_destroy(struct m_snd_tag *mst) | ||||
struct ifnet *ifp; | struct ifnet *ifp; | ||||
ifp = mst->ifp; | ifp = mst->ifp; | ||||
mst->sw->snd_tag_free(mst); | mst->sw->snd_tag_free(mst); | ||||
if_rele(ifp); | if_rele(ifp); | ||||
counter_u64_add(snd_tag_count, -1); | counter_u64_add(snd_tag_count, -1); | ||||
} | } | ||||
void | |||||
m_rcvif_serialize(struct mbuf *m) | |||||
{ | |||||
u_short idx, gen; | |||||
M_ASSERTPKTHDR(m); | |||||
idx = m->m_pkthdr.rcvif->if_index; | |||||
gen = m->m_pkthdr.rcvif->if_idxgen; | |||||
m->m_pkthdr.rcvidx = idx; | |||||
m->m_pkthdr.rcvgen = gen; | |||||
} | |||||
struct ifnet * | |||||
m_rcvif_restore(struct mbuf *m) | |||||
{ | |||||
M_ASSERTPKTHDR(m); | |||||
return ((m->m_pkthdr.rcvif = ifnet_byindexgen(m->m_pkthdr.rcvidx, | |||||
m->m_pkthdr.rcvgen))); | |||||
} | |||||
/* | /* | ||||
* Allocate an mbuf with anonymous external pages. | * Allocate an mbuf with anonymous external pages. | ||||
*/ | */ | ||||
struct mbuf * | struct mbuf * | ||||
mb_alloc_ext_plus_pages(int len, int how) | mb_alloc_ext_plus_pages(int len, int how) | ||||
{ | { | ||||
struct mbuf *m; | struct mbuf *m; | ||||
vm_page_t pg; | vm_page_t pg; | ||||
▲ Show 20 Lines • Show All 92 Lines • Show Last 20 Lines |