From owner-svn-src-user@FreeBSD.ORG Fri Jun 5 14:04:37 2009 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1F1A510656FD; Fri, 5 Jun 2009 14:04:37 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0D9D38FC0C; Fri, 5 Jun 2009 14:04:37 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n55E4ap8027782; Fri, 5 Jun 2009 14:04:36 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n55E4acl027779; Fri, 5 Jun 2009 14:04:36 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <200906051404.n55E4acl027779@svn.freebsd.org> From: Luigi Rizzo Date: Fri, 5 Jun 2009 14:04:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r193505 - in user/luigi/ipfw_80/sys: net netinet X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Jun 2009 14:04:37 -0000 Author: luigi Date: Fri Jun 5 14:04:36 2009 New Revision: 193505 URL: http://svn.freebsd.org/changeset/base/193505 Log: sync ipfw-related changes with head Modified: user/luigi/ipfw_80/sys/net/if_bridge.c user/luigi/ipfw_80/sys/net/if_ethersubr.c user/luigi/ipfw_80/sys/netinet/ip_var.h Modified: user/luigi/ipfw_80/sys/net/if_bridge.c ============================================================================== --- user/luigi/ipfw_80/sys/net/if_bridge.c Fri Jun 5 13:55:33 2009 (r193504) +++ user/luigi/ipfw_80/sys/net/if_bridge.c Fri Jun 5 14:04:36 2009 (r193505) @@ -3041,7 +3041,7 @@ bridge_pfil(struct mbuf **mp, struct ifn goto bad; } - if (IPFW_LOADED && pfil_ipfw != 0 && dir == PFIL_OUT && ifp != NULL) { + if (ip_fw_chk_ptr && pfil_ipfw != 0 && dir == PFIL_OUT && ifp != NULL) { INIT_VNET_INET(curvnet); error = -1; Modified: user/luigi/ipfw_80/sys/net/if_ethersubr.c ============================================================================== --- user/luigi/ipfw_80/sys/net/if_ethersubr.c Fri Jun 5 13:55:33 2009 (r193504) +++ user/luigi/ipfw_80/sys/net/if_ethersubr.c Fri Jun 5 14:04:36 2009 (r193505) @@ -436,7 +436,7 @@ ether_output_frame(struct ifnet *ifp, st INIT_VNET_NET(ifp->if_vnet); struct ip_fw *rule = ip_dn_claim_rule(m); - if (IPFW_LOADED && V_ether_ipfw != 0) { + if (ip_fw_chk_ptr && V_ether_ipfw != 0) { if (ether_ipfw_chk(&m, ifp, &rule, 0) == 0) { if (m) { m_freem(m); @@ -770,7 +770,7 @@ ether_demux(struct ifnet *ifp, struct mb * Allow dummynet and/or ipfw to claim the frame. * Do not do this for PROMISC frames in case we are re-entered. */ - if (IPFW_LOADED && V_ether_ipfw != 0 && !(m->m_flags & M_PROMISC)) { + if (ip_fw_chk_ptr && V_ether_ipfw != 0 && !(m->m_flags & M_PROMISC)) { struct ip_fw *rule = ip_dn_claim_rule(m); if (ether_ipfw_chk(&m, NULL, &rule, 0) == 0) { Modified: user/luigi/ipfw_80/sys/netinet/ip_var.h ============================================================================== --- user/luigi/ipfw_80/sys/netinet/ip_var.h Fri Jun 5 13:55:33 2009 (r193504) +++ user/luigi/ipfw_80/sys/netinet/ip_var.h Fri Jun 5 14:04:36 2009 (r193505) @@ -224,16 +224,13 @@ extern struct pfil_head inet_pfil_hook; void in_delayed_cksum(struct mbuf *m); -/* ipfw and dummynet hooks */ -extern int (*ip_fw_ctl_ptr)(struct sockopt *); +/* ipfw and dummynet hooks. Most are declared in raw_ip.c */ struct ip_fw_args; -extern int (*ip_fw_chk_ptr)(struct ip_fw_args *args); -#define IPFW_LOADED (ip_fw_chk_ptr != NULL) - -extern int (*ip_dn_ctl_ptr)(struct sockopt *); /* raw_ip.c */ -extern int (*ip_dn_io_ptr)(struct mbuf **m, int dir, struct ip_fw_args *fwa); -//typedef void ip_dn_ruledel_t(void *); /* ip_fw_pfil.c */ -extern void (*ip_dn_ruledel_ptr)(void *); /* ip_fw_pfil.c */ +extern int (*ip_fw_chk_ptr)(struct ip_fw_args *args); +extern int (*ip_fw_ctl_ptr)(struct sockopt *); +extern int (*ip_dn_ctl_ptr)(struct sockopt *); +extern int (*ip_dn_io_ptr)(struct mbuf **m, int dir, struct ip_fw_args *fwa); +extern void (*ip_dn_ruledel_ptr)(void *); /* in ip_fw2.c */ #endif /* _KERNEL */ #endif /* !_NETINET_IP_VAR_H_ */