Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/net Remove #ifdef BRIDGE_IPF, compile in the code by def...



details:   https://anonhg.NetBSD.org/src/rev/7740ff782b5a
branches:  trunk
changeset: 936636:7740ff782b5a
user:      maxv <maxv%NetBSD.org@localhost>
date:      Sat Aug 01 06:50:42 2020 +0000

description:
Remove #ifdef BRIDGE_IPF, compile in the code by default. Sent to
tech-net@.

diffstat:

 sys/external/bsd/ipf/netinet/ip_nat.c |   8 ++++----
 sys/net/if_bridge.c                   |  18 ++++--------------
 2 files changed, 8 insertions(+), 18 deletions(-)

diffs (135 lines):

diff -r 0f673097a758 -r 7740ff782b5a sys/external/bsd/ipf/netinet/ip_nat.c
--- a/sys/external/bsd/ipf/netinet/ip_nat.c     Sat Aug 01 06:35:00 2020 +0000
+++ b/sys/external/bsd/ipf/netinet/ip_nat.c     Sat Aug 01 06:50:42 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ip_nat.c,v 1.22 2020/06/24 21:54:57 jdolecek Exp $     */
+/*     $NetBSD: ip_nat.c,v 1.23 2020/08/01 06:50:42 maxv Exp $ */
 
 /*
  * Copyright (C) 2012 by Darren Reed.
@@ -112,7 +112,7 @@
 #if !defined(lint)
 #if defined(__NetBSD__)
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ip_nat.c,v 1.22 2020/06/24 21:54:57 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ip_nat.c,v 1.23 2020/08/01 06:50:42 maxv Exp $");
 #else
 static const char sccsid[] = "@(#)ip_nat.c     1.11 6/5/96 (C) 1995 Darren Reed";
 static const char rcsid[] = "@(#)Id: ip_nat.c,v 1.1.1.2 2012/07/22 13:45:27 darrenr Exp";
@@ -5035,7 +5035,7 @@
                ipf_fix_outcksum(0, &fin->fin_ip->ip_sum, msumd, 0);
        }
 #if !defined(_KERNEL) || defined(MENTAT) || defined(__sgi) || \
-    defined(linux) || defined(BRIDGE_IPF)
+    defined(linux)
        else {
                /*
                 * Strictly speaking, this isn't necessary on BSD
@@ -5147,7 +5147,7 @@
                uh->uh_ulen += fin->fin_plen;
                uh->uh_ulen = htons(uh->uh_ulen);
 #if !defined(_KERNEL) || defined(MENTAT) || defined(__sgi) || \
-    defined(linux) || defined(BRIDGE_IPF)
+    defined(linux)
                ipf_fix_outcksum(0, &ip->ip_sum, sumd, 0);
 #endif
 
diff -r 0f673097a758 -r 7740ff782b5a sys/net/if_bridge.c
--- a/sys/net/if_bridge.c       Sat Aug 01 06:35:00 2020 +0000
+++ b/sys/net/if_bridge.c       Sat Aug 01 06:50:42 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_bridge.c,v 1.173 2020/05/01 22:27:42 jdolecek Exp $ */
+/*     $NetBSD: if_bridge.c,v 1.174 2020/08/01 06:50:43 maxv Exp $     */
 
 /*
  * Copyright 2001 Wasabi Systems, Inc.
@@ -80,10 +80,9 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_bridge.c,v 1.173 2020/05/01 22:27:42 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_bridge.c,v 1.174 2020/08/01 06:50:43 maxv Exp $");
 
 #ifdef _KERNEL_OPT
-#include "opt_bridge_ipf.h"
 #include "opt_inet.h"
 #include "opt_net_mpsafe.h"
 #endif /* _KERNEL_OPT */
@@ -114,19 +113,16 @@
 #include <net/if_bridgevar.h>
 #include <net/ether_sw_offload.h>
 
-#if defined(BRIDGE_IPF)
 /* Used for bridge_ip[6]_checkbasic */
 #include <netinet/in.h>
 #include <netinet/in_systm.h>
 #include <netinet/ip.h>
 #include <netinet/ip_var.h>
 #include <netinet/ip_private.h>                /* XXX */
-
 #include <netinet/ip6.h>
 #include <netinet6/in6_var.h>
 #include <netinet6/ip6_var.h>
 #include <netinet6/ip6_private.h>      /* XXX */
-#endif /* BRIDGE_IPF */
 
 /*
  * Size of the route hash table.  Must be a power of two.
@@ -314,7 +310,6 @@
 static int     bridge_ioctl_sma(struct bridge_softc *, void *);
 static int     bridge_ioctl_sifprio(struct bridge_softc *, void *);
 static int     bridge_ioctl_sifcost(struct bridge_softc *, void *);
-#if defined(BRIDGE_IPF)
 static int     bridge_ioctl_gfilt(struct bridge_softc *, void *);
 static int     bridge_ioctl_sfilt(struct bridge_softc *, void *);
 static int     bridge_ipf(void *, struct mbuf **, struct ifnet *, int);
@@ -322,7 +317,6 @@
 # ifdef INET6
 static int     bridge_ip6_checkbasic(struct mbuf **mp);
 # endif /* INET6 */
-#endif /* BRIDGE_IPF */
 
 struct bridge_control {
        int     (*bc_func)(struct bridge_softc *, void *);
@@ -373,10 +367,10 @@
 [BRDGSIFPRIO] = {bridge_ioctl_sifprio, sizeof(struct ifbreq), BC_F_COPYIN|BC_F_SUSER}, 
 
 [BRDGSIFCOST] = {bridge_ioctl_sifcost, sizeof(struct ifbreq), BC_F_COPYIN|BC_F_SUSER}, 
-#if defined(BRIDGE_IPF)
+
 [BRDGGFILT] = {bridge_ioctl_gfilt, sizeof(struct ifbrparam), BC_F_COPYOUT},
 [BRDGSFILT] = {bridge_ioctl_sfilt, sizeof(struct ifbrparam), BC_F_COPYIN|BC_F_SUSER},
-#endif /* BRIDGE_IPF */
+
 [BRDGGIFS] = {bridge_ioctl_gifs, sizeof(struct ifbifconf), BC_F_XLATEIN|BC_F_XLATEOUT},
 [BRDGRTS] = {bridge_ioctl_rts, sizeof(struct ifbaconf), BC_F_XLATEIN|BC_F_XLATEOUT},
 };
@@ -1313,7 +1307,6 @@
        return 0;
 }
 
-#if defined(BRIDGE_IPF)
 static int
 bridge_ioctl_gfilt(struct bridge_softc *sc, void *arg)
 {
@@ -1349,7 +1342,6 @@
 
        return 0;
 }
-#endif /* BRIDGE_IPF */
 
 static int
 bridge_ioctl_sifcost(struct bridge_softc *sc, void *arg)
@@ -2636,7 +2628,6 @@
        pool_put(&bridge_rtnode_pool, brt);
 }
 
-#if defined(BRIDGE_IPF)
 extern pfil_head_t *inet_pfil_hook;                 /* XXX */
 extern pfil_head_t *inet6_pfil_hook;                /* XXX */
 
@@ -2917,4 +2908,3 @@
        return -1;
 }
 # endif /* INET6 */
-#endif /* BRIDGE_IPF */



Home | Main Index | Thread Index | Old Index