summaryrefslogtreecommitdiffstats
path: root/sys/netinet6/in6_proto.c
diff options
context:
space:
mode:
authorwill <will@FreeBSD.org>2010-08-11 00:51:50 +0000
committerwill <will@FreeBSD.org>2010-08-11 00:51:50 +0000
commitaa4e762c4a720fc3e1b4d3f08d09c5b65bb07735 (patch)
tree5194d90f80d5d4fac28f6f736d5c02cf80511112 /sys/netinet6/in6_proto.c
parent8afd703de9fc0419708d83e8c31c1f0facca78dd (diff)
downloadFreeBSD-src-aa4e762c4a720fc3e1b4d3f08d09c5b65bb07735.zip
FreeBSD-src-aa4e762c4a720fc3e1b4d3f08d09c5b65bb07735.tar.gz
Allow carp(4) to be loaded as a kernel module. Follow precedent set by
bridge(4), lagg(4) etc. and make use of function pointers and pf_proto_register() to hook carp into the network stack. Currently, because of the uncertainty about whether the unload path is free of race condition panics, unloads are disallowed by default. Compiling with CARPMOD_CAN_UNLOAD in CFLAGS removes this anti foot shooting measure. This commit requires IP6PROTOSPACER, introduced in r211115. Reviewed by: bz, simon Approved by: ken (mentor) MFC after: 2 weeks
Diffstat (limited to 'sys/netinet6/in6_proto.c')
-rw-r--r--sys/netinet6/in6_proto.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c
index 4aec9cc..3a8a0e6 100644
--- a/sys/netinet6/in6_proto.c
+++ b/sys/netinet6/in6_proto.c
@@ -67,7 +67,6 @@ __FBSDID("$FreeBSD$");
#include "opt_inet6.h"
#include "opt_ipsec.h"
#include "opt_ipstealth.h"
-#include "opt_carp.h"
#include "opt_sctp.h"
#include "opt_mpath.h"
#include "opt_route.h"
@@ -112,10 +111,6 @@ __FBSDID("$FreeBSD$");
#include <netinet6/pim6_var.h>
#include <netinet6/nd6.h>
-#ifdef DEV_CARP
-#include <netinet/ip_carp.h>
-#endif
-
#ifdef SCTP
#include <netinet/in_pcb.h>
#include <netinet/sctp_pcb.h>
@@ -336,18 +331,6 @@ struct ip6protosw inet6sw[] = {
.pr_ctloutput = rip6_ctloutput,
.pr_usrreqs = &rip6_usrreqs
},
-#ifdef DEV_CARP
-{
- .pr_type = SOCK_RAW,
- .pr_domain = &inet6domain,
- .pr_protocol = IPPROTO_CARP,
- .pr_flags = PR_ATOMIC|PR_ADDR,
- .pr_input = carp6_input,
- .pr_output = rip6_output,
- .pr_ctloutput = rip6_ctloutput,
- .pr_usrreqs = &rip6_usrreqs
-},
-#endif /* DEV_CARP */
/* Spacer n-times for loadable protocols. */
IP6PROTOSPACER,
IP6PROTOSPACER,
OpenPOWER on IntegriCloud