Changeset View
Changeset View
Standalone View
Standalone View
head/sys/net/iflib_clone.c
Show First 20 Lines • Show All 263 Lines • ▼ Show 20 Lines | iflib_clone_register(if_shared_ctx_t sctx) | ||||
if (ip->ip_dc == NULL) | if (ip->ip_dc == NULL) | ||||
goto fail_clone; | goto fail_clone; | ||||
/* XXX --- we can handle clone_advanced later */ | /* XXX --- we can handle clone_advanced later */ | ||||
ip->ip_ifc = if_clone_simple(sctx->isc_name, iflib_clone_create, iflib_clone_destroy, 0); | ip->ip_ifc = if_clone_simple(sctx->isc_name, iflib_clone_create, iflib_clone_destroy, 0); | ||||
if (ip->ip_ifc == NULL) { | if (ip->ip_ifc == NULL) { | ||||
printf("clone_simple failed -- cloned %s devices will not be available\n", sctx->isc_name); | printf("clone_simple failed -- cloned %s devices will not be available\n", sctx->isc_name); | ||||
goto fail_clone; | goto fail_clone; | ||||
} | } | ||||
ifc_flags_set(ip->ip_ifc, IFC_NOGROUP); | |||||
ip->ip_lladdr_tag = EVENTHANDLER_REGISTER(iflladdr_event, | ip->ip_lladdr_tag = EVENTHANDLER_REGISTER(iflladdr_event, | ||||
iflib_iflladdr, NULL, EVENTHANDLER_PRI_ANY); | iflib_iflladdr, NULL, EVENTHANDLER_PRI_ANY); | ||||
if (ip->ip_lladdr_tag == NULL) | if (ip->ip_lladdr_tag == NULL) | ||||
goto fail_addr; | goto fail_addr; | ||||
ip->ip_detach_tag = EVENTHANDLER_REGISTER(ifnet_departure_event, | ip->ip_detach_tag = EVENTHANDLER_REGISTER(ifnet_departure_event, | ||||
iflib_ifdetach, NULL, EVENTHANDLER_PRI_ANY); | iflib_ifdetach, NULL, EVENTHANDLER_PRI_ANY); | ||||
if (ip->ip_detach_tag == NULL) | if (ip->ip_detach_tag == NULL) | ||||
Show All 24 Lines |