From owner-svn-src-projects@FreeBSD.ORG Mon Oct 28 10:32:15 2013 Return-Path: Delivered-To: svn-src-projects@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 986F436A; Mon, 28 Oct 2013 10:32:15 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 763F72237; Mon, 28 Oct 2013 10:32:15 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r9SAWFAV008511; Mon, 28 Oct 2013 10:32:15 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r9SAWEHW008508; Mon, 28 Oct 2013 10:32:14 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201310281032.r9SAWEHW008508@svn.freebsd.org> From: Gleb Smirnoff Date: Mon, 28 Oct 2013 10:32:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r257247 - in projects/ifnet/sys: net netpfil/pf X-SVN-Group: projects MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Oct 2013 10:32:15 -0000 Author: glebius Date: Mon Oct 28 10:32:14 2013 New Revision: 257247 URL: http://svnweb.freebsd.org/changeset/base/257247 Log: Merge head r256150 through r257246. Modified: projects/ifnet/sys/net/if.h projects/ifnet/sys/net/if_var.h projects/ifnet/sys/netpfil/pf/pf.c Directory Properties: projects/ifnet/ (props changed) projects/ifnet/sys/ (props changed) Modified: projects/ifnet/sys/net/if.h ============================================================================== --- projects/ifnet/sys/net/if.h Mon Oct 28 10:12:19 2013 (r257246) +++ projects/ifnet/sys/net/if.h Mon Oct 28 10:32:14 2013 (r257247) @@ -35,10 +35,6 @@ #include -#ifdef _KERNEL -#include -#endif - #if __BSD_VISIBLE /* * does not depend on on most other systems. This @@ -49,8 +45,6 @@ #include #include #endif - -struct ifnet; #endif /* @@ -537,10 +531,4 @@ struct if_nameindex *if_nameindex(void); unsigned int if_nametoindex(const char *); __END_DECLS #endif - -#ifdef _KERNEL -/* XXX - this should go away soon. */ -#include -#endif - #endif /* !_NET_IF_H_ */ Modified: projects/ifnet/sys/net/if_var.h ============================================================================== --- projects/ifnet/sys/net/if_var.h Mon Oct 28 10:12:19 2013 (r257246) +++ projects/ifnet/sys/net/if_var.h Mon Oct 28 10:32:14 2013 (r257247) @@ -58,38 +58,26 @@ * interfaces. These routines live in the files if.c and route.c */ -#ifdef __STDC__ -/* - * Forward structure declarations for function prototypes [sic]. - */ -struct mbuf; -struct thread; -struct rtentry; -struct rt_addrinfo; +struct rtentry; /* ifa_rtrequest */ +struct rt_addrinfo; /* ifa_rtrequest */ struct socket; -struct ether_header; struct carp_if; struct carp_softc; struct ifvlantrunk; -struct route; +struct route; /* if_output */ struct vnet; -#endif - -#include /* get TAILQ macros */ #ifdef _KERNEL -#include -#include +#include /* ifqueue only? */ #include #include #endif /* _KERNEL */ #include #include /* XXX */ -#include /* XXX */ +#include /* struct ifqueue */ #include /* XXX */ #include /* XXX */ -#include /* XXX */ -#include +#include /* if_link_task */ #define IF_DUNIT_NONE -1 @@ -220,8 +208,6 @@ struct ifnet { void *if_pspare[8]; /* 1 netmap, 7 TDB */ }; -typedef void if_init_f_t(void *); - /* * XXX These aliases are terribly dangerous because they could apply * to anything. @@ -367,6 +353,7 @@ void if_maddr_runlock(struct ifnet *ifp) } while(0) #ifdef _KERNEL +#ifdef SYS_EVENTHANDLER_H /* interface link layer address change event */ typedef void (*iflladdr_event_handler_t)(void *, struct ifnet *); EVENTHANDLER_DECLARE(iflladdr_event, iflladdr_event_handler_t); @@ -382,6 +369,7 @@ EVENTHANDLER_DECLARE(ifnet_departure_eve /* 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); +#endif /* SYS_EVENTHANDLER_H */ /* * interface groups @@ -404,6 +392,7 @@ struct ifg_list { TAILQ_ENTRY(ifg_list) ifgl_next; }; +#ifdef SYS_EVENTHANDLER_H /* group attach event */ typedef void (*group_attach_event_handler_t)(void *, struct ifg_group *); EVENTHANDLER_DECLARE(group_attach_event, group_attach_event_handler_t); @@ -413,6 +402,7 @@ EVENTHANDLER_DECLARE(group_detach_event, /* group change event */ typedef void (*group_change_event_handler_t)(void *, const char *); EVENTHANDLER_DECLARE(group_change_event, group_change_event_handler_t); +#endif /* SYS_EVENTHANDLER_H */ #define IF_AFDATA_LOCK_INIT(ifp) \ rw_init(&(ifp)->if_afdata_lock, "if_afdata") Modified: projects/ifnet/sys/netpfil/pf/pf.c ============================================================================== --- projects/ifnet/sys/netpfil/pf/pf.c Mon Oct 28 10:12:19 2013 (r257246) +++ projects/ifnet/sys/netpfil/pf/pf.c Mon Oct 28 10:32:14 2013 (r257247) @@ -4554,7 +4554,7 @@ pf_icmp_state_lookup(struct pf_state_key if ((*state)->rule.ptr->type && (((*state)->direction == direction) ? PF_IN : PF_OUT) != icmp_dir) { - if (pf_status.debug >= PF_DEBUG_MISC) { + if (V_pf_status.debug >= PF_DEBUG_MISC) { printf("pf: icmp type %d in wrong direction (%d): ", icmp_dir, direction); pf_print_state(*state); @@ -4593,6 +4593,8 @@ pf_test_state_icmp(struct pf_state **sta break; #endif /* INET6 */ + default: + panic("%s: proto %d\n", __func__, pd->proto); } if (pf_icmp_mapping(pd, icmptype, &icmp_dir, &multi,