Luigi, On Fri, Nov 22, 2013 at 04:57:51AM +0000, Luigi Rizzo wrote: L> Author: luigi L> Date: Fri Nov 22 04:57:50 2013 L> New Revision: 258463 L> URL: http://svnweb.freebsd.org/changeset/base/258463 L> L> Log: L> make ipfw_check_packet() and ipfw_check_frame() public, L> so they can be used in the userspace version of ipfw/dummynet L> (normally using netmap for the I/O path). L> L> This is the first of a few commits to ease compiling the L> ipfw kernel code in userspace.
Is it possible to put the static word under #ifndef USERSPACE? Or do we want to expose these functions to the rest of kernel? L> Modified: L> head/sys/netpfil/ipfw/ip_fw_pfil.c L> L> Modified: head/sys/netpfil/ipfw/ip_fw_pfil.c L> ============================================================================== L> --- head/sys/netpfil/ipfw/ip_fw_pfil.c Fri Nov 22 04:05:24 2013 (r258462) L> +++ head/sys/netpfil/ipfw/ip_fw_pfil.c Fri Nov 22 04:57:50 2013 (r258463) L> @@ -82,9 +82,9 @@ int ipfw_chg_hook(SYSCTL_HANDLER_ARGS); L> L> /* Forward declarations. */ L> static int ipfw_divert(struct mbuf **, int, struct ipfw_rule_ref *, int); L> -static int ipfw_check_packet(void *, struct mbuf **, struct ifnet *, int, L> +int ipfw_check_packet(void *, struct mbuf **, struct ifnet *, int, L> struct inpcb *); L> -static int ipfw_check_frame(void *, struct mbuf **, struct ifnet *, int, L> +int ipfw_check_frame(void *, struct mbuf **, struct ifnet *, int, L> struct inpcb *); L> L> #ifdef SYSCTL_NODE L> @@ -116,7 +116,7 @@ SYSEND L> * dummynet, divert, netgraph or other modules. L> * The packet may be consumed. L> */ L> -static int L> +int L> ipfw_check_packet(void *arg, struct mbuf **m0, struct ifnet *ifp, int dir, L> struct inpcb *inp) L> { L> @@ -292,7 +292,7 @@ again: L> * Inteface is NULL from ether_demux, and ifp from L> * ether_output_frame. L> */ L> -static int L> +int L> ipfw_check_frame(void *arg, struct mbuf **m0, struct ifnet *dst, int dir, L> struct inpcb *inp) L> { -- Totus tuus, Glebius. _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"