Changeset View
Changeset View
Standalone View
Standalone View
head/sys/compat/linux/linux_ioctl.c
Show First 20 Lines • Show All 2,146 Lines • ▼ Show 20 Lines | #endif | ||||
struct ifaddr *ifa; | struct ifaddr *ifa; | ||||
struct sbuf *sb; | struct sbuf *sb; | ||||
int error, ethno, full = 0, valid_len, max_len; | int error, ethno, full = 0, valid_len, max_len; | ||||
error = copyin(uifc, &ifc, sizeof(ifc)); | error = copyin(uifc, &ifc, sizeof(ifc)); | ||||
if (error != 0) | if (error != 0) | ||||
return (error); | return (error); | ||||
max_len = MAXPHYS - 1; | max_len = maxphys - 1; | ||||
CURVNET_SET(TD_TO_VNET(td)); | CURVNET_SET(TD_TO_VNET(td)); | ||||
/* handle the 'request buffer size' case */ | /* handle the 'request buffer size' case */ | ||||
if ((l_uintptr_t)ifc.ifc_buf == PTROUT(NULL)) { | if ((l_uintptr_t)ifc.ifc_buf == PTROUT(NULL)) { | ||||
ifc.ifc_len = 0; | ifc.ifc_len = 0; | ||||
IFNET_RLOCK(); | IFNET_RLOCK(); | ||||
CK_STAILQ_FOREACH(ifp, &V_ifnet, if_link) { | CK_STAILQ_FOREACH(ifp, &V_ifnet, if_link) { | ||||
CK_STAILQ_FOREACH(ifa, &ifp->if_addrhead, ifa_link) { | CK_STAILQ_FOREACH(ifa, &ifp->if_addrhead, ifa_link) { | ||||
▲ Show 20 Lines • Show All 1,643 Lines • Show Last 20 Lines |