Author: kp Date: Thu Aug 23 16:52:52 2018 New Revision: 338256 URL: https://svnweb.freebsd.org/changeset/base/338256
Log: xen/netfront: Ensure curvnet is set netfront_backend_changed() is called from the xenwatch_thread(), which means that the curvnet is not set. We have to set it before we can call things like arp_ifinit(). PR: 230845 Modified: head/sys/dev/xen/netfront/netfront.c Modified: head/sys/dev/xen/netfront/netfront.c ============================================================================== --- head/sys/dev/xen/netfront/netfront.c Thu Aug 23 16:26:03 2018 (r338255) +++ head/sys/dev/xen/netfront/netfront.c Thu Aug 23 16:52:52 2018 (r338256) @@ -962,6 +962,8 @@ netfront_backend_changed(device_t dev, XenbusState new DPRINTK("newstate=%d\n", newstate); + CURVNET_SET(sc->xn_ifp->if_vnet); + switch (newstate) { case XenbusStateInitialising: case XenbusStateInitialised: @@ -994,6 +996,8 @@ netfront_backend_changed(device_t dev, XenbusState new #endif break; } + + CURVNET_RESTORE(); } /** _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"