Changeset View
Changeset View
Standalone View
Standalone View
sys/net/if_ethersubr.c
Show First 20 Lines • Show All 104 Lines • ▼ Show 20 Lines | |||||
void (*ng_ether_detach_p)(struct ifnet *ifp); | void (*ng_ether_detach_p)(struct ifnet *ifp); | ||||
void (*vlan_input_p)(struct ifnet *, struct mbuf *); | void (*vlan_input_p)(struct ifnet *, struct mbuf *); | ||||
/* if_bridge(4) support */ | /* if_bridge(4) support */ | ||||
void (*bridge_dn_p)(struct mbuf *, struct ifnet *); | void (*bridge_dn_p)(struct mbuf *, struct ifnet *); | ||||
/* if_lagg(4) support */ | /* if_lagg(4) support */ | ||||
struct mbuf *(*lagg_input_p)(struct ifnet *, struct mbuf *); | struct mbuf *(*lagg_input_ethernet_p)(struct ifnet *, struct mbuf *); | ||||
static const u_char etherbroadcastaddr[ETHER_ADDR_LEN] = | static const u_char etherbroadcastaddr[ETHER_ADDR_LEN] = | ||||
{ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; | { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; | ||||
static int ether_resolvemulti(struct ifnet *, struct sockaddr **, | static int ether_resolvemulti(struct ifnet *, struct sockaddr **, | ||||
struct sockaddr *); | struct sockaddr *); | ||||
#ifdef VIMAGE | #ifdef VIMAGE | ||||
static void ether_reassign(struct ifnet *, struct vnet *, char *); | static void ether_reassign(struct ifnet *, struct vnet *, char *); | ||||
▲ Show 20 Lines • Show All 477 Lines • ▼ Show 20 Lines | #endif | ||||
if (ifp->if_flags & IFF_MONITOR) { | if (ifp->if_flags & IFF_MONITOR) { | ||||
m_freem(m); | m_freem(m); | ||||
CURVNET_RESTORE(); | CURVNET_RESTORE(); | ||||
return; | return; | ||||
} | } | ||||
/* Handle input from a lagg(4) port */ | /* Handle input from a lagg(4) port */ | ||||
if (ifp->if_type == IFT_IEEE8023ADLAG) { | if (ifp->if_type == IFT_IEEE8023ADLAG) { | ||||
KASSERT(lagg_input_p != NULL, | KASSERT(lagg_input_ethernet_p != NULL, | ||||
("%s: if_lagg not loaded!", __func__)); | ("%s: if_lagg not loaded!", __func__)); | ||||
m = (*lagg_input_p)(ifp, m); | m = (*lagg_input_ethernet_p)(ifp, m); | ||||
if (m != NULL) | if (m != NULL) | ||||
ifp = m->m_pkthdr.rcvif; | ifp = m->m_pkthdr.rcvif; | ||||
else { | else { | ||||
CURVNET_RESTORE(); | CURVNET_RESTORE(); | ||||
return; | return; | ||||
} | } | ||||
} | } | ||||
▲ Show 20 Lines • Show All 849 Lines • Show Last 20 Lines |