summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2004-08-28 15:24:53 +0000
committerrwatson <rwatson@FreeBSD.org>2004-08-28 15:24:53 +0000
commit289252d030a4f6aa41afcc5c6354239cfdaac243 (patch)
tree1c8237e7bd7fd5f60b3c8ac20e9fd5a425d5f328 /sys
parentfc8849df2ffdb8ac50b59b415847d50cf53186c1 (diff)
downloadFreeBSD-src-289252d030a4f6aa41afcc5c6354239cfdaac243.zip
FreeBSD-src-289252d030a4f6aa41afcc5c6354239cfdaac243.tar.gz
Mark Netgraph TTY, KAME IPSEC, and IPX/SPX as requiring Giant for correct
operation using NET_NEEDS_GIANT(). This will result in a boot-time restoration of Giant-enabled network operation, or run-time warning on dynamic load (applicable only to the Netgraph component). Additional components will likely need to be marked with this in the future.
Diffstat (limited to 'sys')
-rw-r--r--sys/netgraph/ng_tty.c2
-rw-r--r--sys/netinet6/ipsec.c2
-rw-r--r--sys/netipx/ipx.c6
3 files changed, 10 insertions, 0 deletions
diff --git a/sys/netgraph/ng_tty.c b/sys/netgraph/ng_tty.c
index bd341da..9ae20a0 100644
--- a/sys/netgraph/ng_tty.c
+++ b/sys/netgraph/ng_tty.c
@@ -75,6 +75,8 @@
#include <netgraph/netgraph.h>
#include <netgraph/ng_tty.h>
+NET_NEEDS_GIANT("ng_tty");
+
/* Misc defs */
#define MAX_MBUFQ 3 /* Max number of queued mbufs */
#define NGT_HIWATER 400 /* High water mark on output */
diff --git a/sys/netinet6/ipsec.c b/sys/netinet6/ipsec.c
index 13d2feb..6f3dd5c 100644
--- a/sys/netinet6/ipsec.c
+++ b/sys/netinet6/ipsec.c
@@ -110,6 +110,8 @@ int ipsec_debug = 1;
int ipsec_debug = 0;
#endif
+NET_NEEDS_GIANT("ipsec");
+
struct ipsecstat ipsecstat;
int ip4_ah_cleartos = 1;
int ip4_ah_offsetmask = 0; /* maybe IP_DF? */
diff --git a/sys/netipx/ipx.c b/sys/netipx/ipx.c
index af7ba49..840f802 100644
--- a/sys/netipx/ipx.c
+++ b/sys/netipx/ipx.c
@@ -38,6 +38,7 @@
__FBSDID("$FreeBSD$");
#include <sys/param.h>
+#include <sys/kernel.h>
#include <sys/systm.h>
#include <sys/malloc.h>
#include <sys/sockio.h>
@@ -50,6 +51,11 @@ __FBSDID("$FreeBSD$");
#include <netipx/ipx_if.h>
#include <netipx/ipx_var.h>
+NET_NEEDS_GIANT("ipx");
+
+/*
+ * XXXRW: Requires synchronization.
+ */
struct ipx_ifaddr *ipx_ifaddr;
static void ipx_ifscrub(struct ifnet *ifp, struct ipx_ifaddr *ia);
OpenPOWER on IntegriCloud