Deleted Added
full compact
nd6.c (215423) nd6.c (215701)
1/*-
2 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 16 unchanged lines hidden (view full) ---

25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * $KAME: nd6.c,v 1.144 2001/05/24 07:44:00 itojun Exp $
30 */
31
32#include <sys/cdefs.h>
1/*-
2 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 16 unchanged lines hidden (view full) ---

25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * $KAME: nd6.c,v 1.144 2001/05/24 07:44:00 itojun Exp $
30 */
31
32#include <sys/cdefs.h>
33__FBSDID("$FreeBSD: head/sys/netinet6/nd6.c 215423 2010-11-17 10:43:20Z bz $");
33__FBSDID("$FreeBSD: head/sys/netinet6/nd6.c 215701 2010-11-22 19:32:54Z dim $");
34
35#include "opt_inet.h"
36#include "opt_inet6.h"
37
38#include <sys/param.h>
39#include <sys/systm.h>
40#include <sys/callout.h>
41#include <sys/malloc.h>

--- 47 unchanged lines hidden (view full) ---

89VNET_DEFINE(int, nd6_umaxtries) = 3; /* maximum unicast query */
90VNET_DEFINE(int, nd6_mmaxtries) = 3; /* maximum multicast query */
91VNET_DEFINE(int, nd6_useloopback) = 1; /* use loopback interface for
92 * local traffic */
93VNET_DEFINE(int, nd6_gctimer) = (60 * 60 * 24); /* 1 day: garbage
94 * collection timer */
95
96/* preventing too many loops in ND option parsing */
34
35#include "opt_inet.h"
36#include "opt_inet6.h"
37
38#include <sys/param.h>
39#include <sys/systm.h>
40#include <sys/callout.h>
41#include <sys/malloc.h>

--- 47 unchanged lines hidden (view full) ---

89VNET_DEFINE(int, nd6_umaxtries) = 3; /* maximum unicast query */
90VNET_DEFINE(int, nd6_mmaxtries) = 3; /* maximum multicast query */
91VNET_DEFINE(int, nd6_useloopback) = 1; /* use loopback interface for
92 * local traffic */
93VNET_DEFINE(int, nd6_gctimer) = (60 * 60 * 24); /* 1 day: garbage
94 * collection timer */
95
96/* preventing too many loops in ND option parsing */
97STATIC_VNET_DEFINE(int, nd6_maxndopt) = 10; /* max # of ND options allowed */
97static VNET_DEFINE(int, nd6_maxndopt) = 10; /* max # of ND options allowed */
98
99VNET_DEFINE(int, nd6_maxnudhint) = 0; /* max # of subsequent upper
100 * layer hints */
98
99VNET_DEFINE(int, nd6_maxnudhint) = 0; /* max # of subsequent upper
100 * layer hints */
101STATIC_VNET_DEFINE(int, nd6_maxqueuelen) = 1; /* max pkts cached in unresolved
101static VNET_DEFINE(int, nd6_maxqueuelen) = 1; /* max pkts cached in unresolved
102 * ND entries */
103#define V_nd6_maxndopt VNET(nd6_maxndopt)
104#define V_nd6_maxqueuelen VNET(nd6_maxqueuelen)
105
106#ifdef ND6_DEBUG
107VNET_DEFINE(int, nd6_debug) = 1;
108#else
109VNET_DEFINE(int, nd6_debug) = 0;

--- 18 unchanged lines hidden (view full) ---

128 struct ifnet *));
129static void nd6_setmtu0(struct ifnet *, struct nd_ifinfo *);
130static void nd6_slowtimo(void *);
131static int regen_tmpaddr(struct in6_ifaddr *);
132static struct llentry *nd6_free(struct llentry *, int);
133static void nd6_llinfo_timer(void *);
134static void clear_llinfo_pqueue(struct llentry *);
135
102 * ND entries */
103#define V_nd6_maxndopt VNET(nd6_maxndopt)
104#define V_nd6_maxqueuelen VNET(nd6_maxqueuelen)
105
106#ifdef ND6_DEBUG
107VNET_DEFINE(int, nd6_debug) = 1;
108#else
109VNET_DEFINE(int, nd6_debug) = 0;

--- 18 unchanged lines hidden (view full) ---

128 struct ifnet *));
129static void nd6_setmtu0(struct ifnet *, struct nd_ifinfo *);
130static void nd6_slowtimo(void *);
131static int regen_tmpaddr(struct in6_ifaddr *);
132static struct llentry *nd6_free(struct llentry *, int);
133static void nd6_llinfo_timer(void *);
134static void clear_llinfo_pqueue(struct llentry *);
135
136STATIC_VNET_DEFINE(struct callout, nd6_slowtimo_ch);
136static VNET_DEFINE(struct callout, nd6_slowtimo_ch);
137#define V_nd6_slowtimo_ch VNET(nd6_slowtimo_ch)
138
139VNET_DEFINE(struct callout, nd6_timer_ch);
140
141void
142nd6_init(void)
143{
144 int i;

--- 2159 unchanged lines hidden ---
137#define V_nd6_slowtimo_ch VNET(nd6_slowtimo_ch)
138
139VNET_DEFINE(struct callout, nd6_timer_ch);
140
141void
142nd6_init(void)
143{
144 int i;

--- 2159 unchanged lines hidden ---