Date: Thu, 26 Jan 2017 16:04:39 +0000 From: "decui_microsoft.com (Dexuan Cui)" <phabric-noreply@FreeBSD.org> To: freebsd-net@freebsd.org Subject: [Differential] D9345: ifnet: move the new ifnet_event EVENTHANDLER_DECLARE to net/if_var.h Message-ID: <e133e2f9cd01f535aa2a4ad47476bdd3@localhost.localdomain> In-Reply-To: <differential-rev-PHID-DREV-ehgwxeotuhsw6eo52uz6-req@FreeBSD.org> References: <differential-rev-PHID-DREV-ehgwxeotuhsw6eo52uz6-req@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --] decui_microsoft.com updated this revision to Diff 24479. decui_microsoft.com added a comment. This revision now requires review to proceed. fixed the comment typo pointed out by David. CHANGES SINCE LAST UPDATE https://reviews.freebsd.org/D9345?vs=24465&id=24479 REVISION DETAIL https://reviews.freebsd.org/D9345 AFFECTED FILES sys/net/if.c sys/net/if_var.h sys/sys/eventhandler.h EMAIL PREFERENCES https://reviews.freebsd.org/settings/panel/emailpreferences/ To: decui_microsoft.com, hselasky, sepherosa_gmail.com, cem, np, kmacy, kib, honzhan_microsoft.com, howard0su_gmail.com, jhb, ae, delphij, royger, glebius, gnn, rwatson, David_A_Bright_DELL.com Cc: David_A_Bright_DELL.com, freebsd-net-list [-- Attachment #2 --] diff --git a/sys/sys/eventhandler.h b/sys/sys/eventhandler.h --- a/sys/sys/eventhandler.h +++ b/sys/sys/eventhandler.h @@ -284,11 +284,4 @@ EVENTHANDLER_DECLARE(swapon, swapon_fn); EVENTHANDLER_DECLARE(swapoff, swapoff_fn); -/* ifup/ifdown events */ -#define IFNET_EVENT_UP 0 -#define IFNET_EVENT_DOWN 1 -struct ifnet; -typedef void (*ifnet_event_fn)(void *, struct ifnet *ifp, int event); -EVENTHANDLER_DECLARE(ifnet_event, ifnet_event_fn); - #endif /* _SYS_EVENTHANDLER_H_ */ diff --git a/sys/net/if_var.h b/sys/net/if_var.h --- a/sys/net/if_var.h +++ b/sys/net/if_var.h @@ -404,6 +404,11 @@ /* Interface link state change event */ typedef void (*ifnet_link_event_handler_t)(void *, struct ifnet *, int); EVENTHANDLER_DECLARE(ifnet_link_event, ifnet_link_event_handler_t); +/* Interface up/down event */ +#define IFNET_EVENT_UP 0 +#define IFNET_EVENT_DOWN 1 +typedef void (*ifnet_event_fn)(void *, struct ifnet *ifp, int event); +EVENTHANDLER_DECLARE(ifnet_event, ifnet_event_fn); #endif /* _SYS_EVENTHANDLER_H_ */ /* diff --git a/sys/net/if.c b/sys/net/if.c --- a/sys/net/if.c +++ b/sys/net/if.c @@ -59,7 +59,6 @@ #include <sys/domain.h> #include <sys/jail.h> #include <sys/priv.h> -#include <sys/eventhandler.h> #include <machine/stdarg.h> #include <vm/uma.h>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?e133e2f9cd01f535aa2a4ad47476bdd3>
