Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 8 Feb 2010 05:39:32 +0000 (UTC)
From:      Kip Macy <kmacy@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r203652 - user/kmacy/head_flowtable_v6/sys/netinet6
Message-ID:  <201002080539.o185dW6l047944@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kmacy
Date: Mon Feb  8 05:39:32 2010
New Revision: 203652
URL: http://svn.freebsd.org/changeset/base/203652

Log:
  - add opt_route.h so that FLOWTABLE can be defined
  - shuffle variables and fix call to flowtable_alloc

Modified:
  user/kmacy/head_flowtable_v6/sys/netinet6/in6_proto.c
  user/kmacy/head_flowtable_v6/sys/netinet6/ip6_input.c
  user/kmacy/head_flowtable_v6/sys/netinet6/ip6_output.c

Modified: user/kmacy/head_flowtable_v6/sys/netinet6/in6_proto.c
==============================================================================
--- user/kmacy/head_flowtable_v6/sys/netinet6/in6_proto.c	Mon Feb  8 05:13:08 2010	(r203651)
+++ user/kmacy/head_flowtable_v6/sys/netinet6/in6_proto.c	Mon Feb  8 05:39:32 2010	(r203652)
@@ -70,6 +70,7 @@ __FBSDID("$FreeBSD$");
 #include "opt_carp.h"
 #include "opt_sctp.h"
 #include "opt_mpath.h"
+#include "opt_route.h"
 
 #include <sys/param.h>
 #include <sys/socket.h>
@@ -130,6 +131,10 @@ __FBSDID("$FreeBSD$");
 
 #include <netinet6/ip6protosw.h>
 
+#ifdef FLOWTABLE
+#include <net/flowtable.h>
+#endif
+
 /*
  * TCP/IP protocol family: IP6, ICMP6, UDP, TCP.
  */
@@ -547,7 +552,7 @@ SYSCTL_VNET_INT(_net_inet6_ip6, IPV6CTL_
 #endif
 
 #ifdef FLOWTABLE
-static VNET_DEFINE(int, ip6_output_flowtable_size) = 2048;
+VNET_DEFINE(int, ip6_output_flowtable_size) = 2048;
 VNET_DEFINE(struct flowtable *, ip6_ft);
 #define	V_ip6_output_flowtable_size	VNET(ip6_output_flowtable_size)
 

Modified: user/kmacy/head_flowtable_v6/sys/netinet6/ip6_input.c
==============================================================================
--- user/kmacy/head_flowtable_v6/sys/netinet6/ip6_input.c	Mon Feb  8 05:13:08 2010	(r203651)
+++ user/kmacy/head_flowtable_v6/sys/netinet6/ip6_input.c	Mon Feb  8 05:39:32 2010	(r203652)
@@ -66,6 +66,7 @@ __FBSDID("$FreeBSD$");
 #include "opt_inet.h"
 #include "opt_inet6.h"
 #include "opt_ipsec.h"
+#include "opt_route.h"
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -113,6 +114,12 @@ __FBSDID("$FreeBSD$");
 
 #include <netinet6/ip6protosw.h>
 
+#ifdef FLOWTABLE
+#include <net/flowtable.h>
+extern VNET_DEFINE(int, ip6_output_flowtable_size);
+#define	V_ip6_output_flowtable_size	VNET(ip6_output_flowtable_size)
+#endif
+
 extern struct domain inet6domain;
 
 u_char ip6_protox[IPPROTO_MAX];
@@ -195,7 +202,7 @@ ip6_init(void)
 #ifdef FLOWTABLE
 	TUNABLE_INT_FETCH("net.inet6.ip6.output_flowtable_size",
 	    &V_ip6_output_flowtable_size);
-	V_ip6_ft = flowtable_alloc(V_ip6_output_flowtable_size, FL_PCPU);
+	V_ip6_ft = flowtable_alloc("ipv6", V_ip6_output_flowtable_size, FL_PCPU);
 #endif
 	V_ip6_forwarding = IPV6FORWARDING; /* act as router? */
 	V_ip6_sendredirects = IPV6_SENDREDIRECTS;

Modified: user/kmacy/head_flowtable_v6/sys/netinet6/ip6_output.c
==============================================================================
--- user/kmacy/head_flowtable_v6/sys/netinet6/ip6_output.c	Mon Feb  8 05:13:08 2010	(r203651)
+++ user/kmacy/head_flowtable_v6/sys/netinet6/ip6_output.c	Mon Feb  8 05:39:32 2010	(r203652)
@@ -66,6 +66,7 @@ __FBSDID("$FreeBSD$");
 #include "opt_inet.h"
 #include "opt_inet6.h"
 #include "opt_ipsec.h"
+#include "opt_route.h"
 
 #include <sys/param.h>
 #include <sys/kernel.h>
@@ -106,6 +107,10 @@ __FBSDID("$FreeBSD$");
 #include <netinet6/ip6protosw.h>
 #include <netinet6/scope6_var.h>
 
+#ifdef FLOWTABLE
+#include <net/flowtable.h>
+#endif
+
 extern int in6_mcast_loop;
 
 struct ip6_exthdrs {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201002080539.o185dW6l047944>