diff --git a/sys/net/if.c b/sys/net/if.c index e457ce5c4705..a7aed084143c 100644 --- a/sys/net/if.c +++ b/sys/net/if.c @@ -1314,21 +1314,9 @@ static int if_vmove(struct ifnet *ifp, struct vnet *new_vnet) { struct if_clone *ifc; -#ifdef DEV_BPF - u_int bif_dlt, bif_hdrlen; -#endif void *old; int rc; -#ifdef DEV_BPF - /* - * if_detach_internal() will call the eventhandler to notify - * interface departure. That will detach if_bpf. We need to - * safe the dlt and hdrlen so we can re-attach it later. - */ - bpf_get_bp_params(ifp->if_bpf, &bif_dlt, &bif_hdrlen); -#endif - /* * Detach from current vnet, but preserve LLADDR info, do not * mark as dead etc. so that the ifnet can be reattached later. @@ -1374,11 +1362,6 @@ if_vmove(struct ifnet *ifp, struct vnet *new_vnet) if_attach_internal(ifp, 1, ifc); -#ifdef DEV_BPF - if (ifp->if_bpf == NULL) - bpfattach(ifp, bif_dlt, bif_hdrlen); -#endif - CURVNET_RESTORE(); return (0); }