summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2018-11-19 10:15:05 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2018-11-19 10:15:05 +0000
commit62d9be4dcca6e2659bf9d032251d71df9be3a8d9 (patch)
tree401bdc60c14193219d36374f080984c1406b424d /sys
parentfaefb1a165837c0bc7a25aaf60c8253877efc51d (diff)
Retire dom_rtkeylen from struct domain. Nothing is using this anymore.
It was used by the original patricia tree. OK mpi@
Diffstat (limited to 'sys')
-rw-r--r--sys/net/rtable.c12
-rw-r--r--sys/netinet/in_proto.c3
-rw-r--r--sys/netinet6/in6_proto.c3
-rw-r--r--sys/netmpls/mpls_proto.c3
-rw-r--r--sys/sys/domain.h3
5 files changed, 8 insertions, 16 deletions
diff --git a/sys/net/rtable.c b/sys/net/rtable.c
index 9dd3e2ee542..d16fed8f7eb 100644
--- a/sys/net/rtable.c
+++ b/sys/net/rtable.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rtable.c,v 1.64 2018/09/09 10:07:38 henning Exp $ */
+/* $OpenBSD: rtable.c,v 1.65 2018/11/19 10:15:04 claudio Exp $ */
/*
* Copyright (c) 2014-2016 Martin Pieuchot
@@ -83,7 +83,7 @@ void rtmap_dtor(void *, void *);
struct srp_gc rtmap_gc = SRP_GC_INITIALIZER(rtmap_dtor, NULL);
-void rtable_init_backend(unsigned int);
+void rtable_init_backend(void);
void *rtable_alloc(unsigned int, unsigned int, unsigned int);
void *rtable_get(unsigned int, sa_family_t);
@@ -153,7 +153,6 @@ void
rtable_init(void)
{
struct domain *dp;
- unsigned int keylen = 0;
int i;
KASSERT(sizeof(struct rtmap) == sizeof(struct dommp));
@@ -171,11 +170,8 @@ rtable_init(void)
continue;
af2idx[dp->dom_family] = af2idx_max++;
- if (dp->dom_rtkeylen > keylen)
- keylen = dp->dom_rtkeylen;
-
}
- rtable_init_backend(keylen);
+ rtable_init_backend();
/*
* Allocate AF-to-id table now that we now how many AFs this
@@ -358,7 +354,7 @@ void rtable_mpath_insert(struct art_node *, struct rtentry *);
struct srpl_rc rt_rc = SRPL_RC_INITIALIZER(rtentry_ref, rtentry_unref, NULL);
void
-rtable_init_backend(unsigned int keylen)
+rtable_init_backend(void)
{
art_init();
}
diff --git a/sys/netinet/in_proto.c b/sys/netinet/in_proto.c
index e50680e6f04..da4a5d8034b 100644
--- a/sys/netinet/in_proto.c
+++ b/sys/netinet/in_proto.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: in_proto.c,v 1.90 2018/02/10 08:12:01 dlg Exp $ */
+/* $OpenBSD: in_proto.c,v 1.91 2018/11/19 10:15:04 claudio Exp $ */
/* $NetBSD: in_proto.c,v 1.14 1996/02/18 18:58:32 christos Exp $ */
/*
@@ -443,7 +443,6 @@ struct domain inetdomain = {
.dom_name = "internet",
.dom_protosw = inetsw,
.dom_protoswNPROTOSW = &inetsw[nitems(inetsw)],
- .dom_rtkeylen = sizeof(struct sockaddr_in),
.dom_rtoffset = offsetof(struct sockaddr_in, sin_addr),
.dom_maxplen = 32
};
diff --git a/sys/netinet6/in6_proto.c b/sys/netinet6/in6_proto.c
index 3be98fd1b9a..3667fe75079 100644
--- a/sys/netinet6/in6_proto.c
+++ b/sys/netinet6/in6_proto.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: in6_proto.c,v 1.102 2018/02/10 08:12:01 dlg Exp $ */
+/* $OpenBSD: in6_proto.c,v 1.103 2018/11/19 10:15:04 claudio Exp $ */
/* $KAME: in6_proto.c,v 1.66 2000/10/10 15:35:47 itojun Exp $ */
/*
@@ -366,7 +366,6 @@ struct domain inet6domain = {
.dom_name = "internet6",
.dom_protosw = inet6sw,
.dom_protoswNPROTOSW = &inet6sw[nitems(inet6sw)],
- .dom_rtkeylen = sizeof(struct sockaddr_in6),
.dom_rtoffset = offsetof(struct sockaddr_in6, sin6_addr),
.dom_maxplen = 128,
.dom_ifattach = in6_domifattach,
diff --git a/sys/netmpls/mpls_proto.c b/sys/netmpls/mpls_proto.c
index 80f0ea8bdb1..e191c4cabc4 100644
--- a/sys/netmpls/mpls_proto.c
+++ b/sys/netmpls/mpls_proto.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpls_proto.c,v 1.16 2017/03/02 08:58:24 mpi Exp $ */
+/* $OpenBSD: mpls_proto.c,v 1.17 2018/11/19 10:15:04 claudio Exp $ */
/*
* Copyright (C) 1999, 2000 and 2001 AYAME Project, WIDE Project.
@@ -48,7 +48,6 @@
struct domain mplsdomain = {
.dom_family = AF_MPLS,
.dom_name = "mpls",
- .dom_rtkeylen = sizeof(struct sockaddr_mpls),
.dom_rtoffset = offsetof(struct sockaddr_mpls, smpls_label),
.dom_maxplen = 32
};
diff --git a/sys/sys/domain.h b/sys/sys/domain.h
index 8cf580aff7c..8359cfa3329 100644
--- a/sys/sys/domain.h
+++ b/sys/sys/domain.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: domain.h,v 1.18 2017/11/23 13:45:46 mpi Exp $ */
+/* $OpenBSD: domain.h,v 1.19 2018/11/19 10:15:04 claudio Exp $ */
/* $NetBSD: domain.h,v 1.10 1996/02/09 18:25:07 christos Exp $ */
/*
@@ -57,7 +57,6 @@ struct domain {
void (*dom_dispose)(struct mbuf *);
const struct protosw *dom_protosw, *dom_protoswNPROTOSW;
/* initialize routing table */
- unsigned int dom_rtkeylen; /* maximum size of the key */
unsigned int dom_rtoffset; /* offset of the key, in bytes */
unsigned int dom_maxplen; /* maxium prefix length, in bits */
void *(*dom_ifattach)(struct ifnet *);