summaryrefslogtreecommitdiff
path: root/sys/netinet/ip_input.c
diff options
context:
space:
mode:
authorMartin Pieuchot <mpi@cvs.openbsd.org>2017-11-23 13:45:47 +0000
committerMartin Pieuchot <mpi@cvs.openbsd.org>2017-11-23 13:45:47 +0000
commit08df52708934e060b4a1703b6567cb299daf5441 (patch)
tree8c608d3172e9a4c994684d0350632d2f0e9f62fd /sys/netinet/ip_input.c
parent7e36b61cd38a09ad7df4709cfc0a24d47bca6ced (diff)
Constify protocol tables and remove an assert now that ip_deliver() is
mp-safe. ok bluhm@, visa@
Diffstat (limited to 'sys/netinet/ip_input.c')
-rw-r--r--sys/netinet/ip_input.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c
index 5eee0d5eac5..695cf415b1c 100644
--- a/sys/netinet/ip_input.c
+++ b/sys/netinet/ip_input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip_input.c,v 1.333 2017/11/20 10:35:24 mpi Exp $ */
+/* $OpenBSD: ip_input.c,v 1.334 2017/11/23 13:45:46 mpi Exp $ */
/* $NetBSD: ip_input.c,v 1.30 1996/03/16 23:53:58 christos Exp $ */
/*
@@ -151,7 +151,7 @@ void save_rte(struct mbuf *, u_char *, struct in_addr);
void
ip_init(void)
{
- struct protosw *pr;
+ const struct protosw *pr;
int i;
const u_int16_t defbaddynamicports_tcp[] = DEFBADDYNAMICPORTS_TCP;
const u_int16_t defbaddynamicports_udp[] = DEFBADDYNAMICPORTS_UDP;
@@ -613,14 +613,12 @@ ip_local(struct mbuf **mp, int *offp, int nxt, int af)
int
ip_deliver(struct mbuf **mp, int *offp, int nxt, int af)
{
- struct protosw *psw;
+ const struct protosw *psw;
int naf = af;
#ifdef INET6
int nest = 0;
#endif /* INET6 */
- KERNEL_ASSERT_LOCKED();
-
/* pf might have modified stuff, might have to chksum */
switch (af) {
case AF_INET: