RE: svn commit: r312687 - in head/sys: net sys
> From: Dexuan Cui [mailto:de...@microsoft.com] > Sent: Wednesday, January 25, 2017 06:21 > To: Gleb Smirnoff <gleb...@freebsd.org>; Dexuan Cui <dex...@freebsd.org> > Cc: src-committ...@freebsd.org; svn-src-all@freebsd.org; svn-src- > h...@freebsd.org > Subject: RE: svn commit: r312687 - in head/sys: net sys > > > From: Gleb Smirnoff [mailto:gleb...@freebsd.org] > > Dexuan, > > > > On Tue, Jan 24, 2017 at 09:19:47AM +, Dexuan Cui wrote: > > D> --- head/sys/sys/eventhandler.h Tue Jan 24 09:15:36 2017 > > (r312686) > > D> +++ head/sys/sys/eventhandler.h Tue Jan 24 09:19:46 2017 > > (r312687) > > D> @@ -284,4 +284,11 @@ typedef void (*swapoff_fn)(void *, struc > > D> EVENTHANDLER_DECLARE(swapon, swapon_fn); > > D> EVENTHANDLER_DECLARE(swapoff, swapoff_fn); > > D> > > D> +/* ifup/ifdown events */ > > D> +#define IFNET_EVENT_UP 0 > > D> +#define IFNET_EVENT_DOWN1 > > D> +struct ifnet; > > D> +typedef void (*ifnet_event_fn)(void *, struct ifnet *ifp, int event); > > D> +EVENTHANDLER_DECLARE(ifnet_event, ifnet_event_fn); > > D> + > > D> #endif /* _SYS_EVENTHANDLER_H_ */ > > > > The network stuff shall not be added to sys/eventhandler.h. > > > > All these declarations should go to net/if_var.h. There is already > > a block of event(9) defines there. Please move it there. > > > > -- > > Totus tuus, Glebius. > > Hi Gleb, > Sorry, I didn't realize this... I'll move it as you suggested. > > Thank you for the reminder! > > -- Dexuan I posted https://reviews.freebsd.org/D9345 for this. Please review it. Thanks, -- Dexuan ___ svn-src-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"
RE: svn commit: r312687 - in head/sys: net sys
> From: Gleb Smirnoff [mailto:gleb...@freebsd.org] > Dexuan, > > On Tue, Jan 24, 2017 at 09:19:47AM +, Dexuan Cui wrote: > D> --- head/sys/sys/eventhandler.hTue Jan 24 09:15:36 2017 > (r312686) > D> +++ head/sys/sys/eventhandler.hTue Jan 24 09:19:46 2017 > (r312687) > D> @@ -284,4 +284,11 @@ typedef void (*swapoff_fn)(void *, struc > D> EVENTHANDLER_DECLARE(swapon, swapon_fn); > D> EVENTHANDLER_DECLARE(swapoff, swapoff_fn); > D> > D> +/* ifup/ifdown events */ > D> +#define IFNET_EVENT_UP0 > D> +#define IFNET_EVENT_DOWN 1 > D> +struct ifnet; > D> +typedef void (*ifnet_event_fn)(void *, struct ifnet *ifp, int event); > D> +EVENTHANDLER_DECLARE(ifnet_event, ifnet_event_fn); > D> + > D> #endif /* _SYS_EVENTHANDLER_H_ */ > > The network stuff shall not be added to sys/eventhandler.h. > > All these declarations should go to net/if_var.h. There is already > a block of event(9) defines there. Please move it there. > > -- > Totus tuus, Glebius. Hi Gleb, Sorry, I didn't realize this... I'll move it as you suggested. Thank you for the reminder! -- Dexuan ___ svn-src-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"
Re: svn commit: r312687 - in head/sys: net sys
Dexuan, On Tue, Jan 24, 2017 at 09:19:47AM +, Dexuan Cui wrote: D> Author: dexuan D> Date: Tue Jan 24 09:19:46 2017 D> New Revision: 312687 D> URL: https://svnweb.freebsd.org/changeset/base/312687 D> D> Log: D> ifnet: introduce event handlers for ifup/ifdown events D> D> Hyper-V's NIC SR-IOV implementation needs a Hyper-V synthetic NIC and D> a VF NIC to work together, mainly to support seamless live migration. D> D> When the VF device becomes UP (or DOWN), the synthetic NIC driver needs D> to switch the data path from the synthetic NIC to the VF (or the opposite). D> D> So the synthetic NIC driver needs to know when a VF device is becoming D> UP or DOWN and hence the patch is made. D> D> Reviewed by: sephe D> Approved by: sephe (mentor) D> MFC after: 2 weeks D> Sponsored by: Microsoft D> Differential Revision: https://reviews.freebsd.org/D8963 D> D> Modified: D> head/sys/net/if.c D> head/sys/sys/eventhandler.h ... D> Modified: head/sys/sys/eventhandler.h D> == D> --- head/sys/sys/eventhandler.h Tue Jan 24 09:15:36 2017 (r312686) D> +++ head/sys/sys/eventhandler.h Tue Jan 24 09:19:46 2017 (r312687) D> @@ -284,4 +284,11 @@ typedef void (*swapoff_fn)(void *, struc D> EVENTHANDLER_DECLARE(swapon, swapon_fn); D> EVENTHANDLER_DECLARE(swapoff, swapoff_fn); D> D> +/* ifup/ifdown events */ D> +#define IFNET_EVENT_UP 0 D> +#define IFNET_EVENT_DOWN1 D> +struct ifnet; D> +typedef void (*ifnet_event_fn)(void *, struct ifnet *ifp, int event); D> +EVENTHANDLER_DECLARE(ifnet_event, ifnet_event_fn); D> + D> #endif /* _SYS_EVENTHANDLER_H_ */ The network stuff shall not be added to sys/eventhandler.h. All these declarations should go to net/if_var.h. There is already a block of event(9) defines there. Please move it there. -- Totus tuus, Glebius. ___ svn-src-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"