summaryrefslogtreecommitdiff
path: root/sys/netinet
diff options
context:
space:
mode:
authorAlexander Bluhm <bluhm@cvs.openbsd.org>2017-08-08 12:23:57 +0000
committerAlexander Bluhm <bluhm@cvs.openbsd.org>2017-08-08 12:23:57 +0000
commit53ba93879ddf5dc8ac4e9eac301f5510dd1b4dbc (patch)
tree2f993f2cb613aa44a14afa293d781d0ff4b1abe0 /sys/netinet
parent07981adedbcfd2eaba0c4767799613b3b572d302 (diff)
Increase the limit of the IP protocol queues from 256 to 2048 mbufs.
The interface congestion algorithm kills performance at this place, with the large queues it never triggers. OK mpi@ claudio@
Diffstat (limited to 'sys/netinet')
-rw-r--r--sys/netinet/ip.h6
-rw-r--r--sys/netinet/ip_input.c4
2 files changed, 7 insertions, 3 deletions
diff --git a/sys/netinet/ip.h b/sys/netinet/ip.h
index a208fcd8f8d..55779429d4a 100644
--- a/sys/netinet/ip.h
+++ b/sys/netinet/ip.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip.h,v 1.16 2014/07/13 13:57:56 mpi Exp $ */
+/* $OpenBSD: ip.h,v 1.17 2017/08/08 12:23:56 bluhm Exp $ */
/* $NetBSD: ip.h,v 1.9 1995/05/15 01:22:44 cgd Exp $ */
/*
@@ -209,6 +209,10 @@ struct ip_timestamp {
#define IP_MSS 576 /* default maximum segment size */
#ifdef _KERNEL
+
+/* Maximum lenght for IP protocol queues */
+#define IPQ_MAXLEN 2048
+
/*
* This is the real IPv4 pseudo header, used for computing the TCP and UDP
* checksums. For the Internet checksum, struct ipovly can be used instead.
diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c
index 3f74687177d..e1f7483f409 100644
--- a/sys/netinet/ip_input.c
+++ b/sys/netinet/ip_input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip_input.c,v 1.316 2017/08/04 14:24:05 florian Exp $ */
+/* $OpenBSD: ip_input.c,v 1.317 2017/08/08 12:23:56 bluhm Exp $ */
/* $NetBSD: ip_input.c,v 1.30 1996/03/16 23:53:58 christos Exp $ */
/*
@@ -120,7 +120,7 @@ int ip_frags = 0;
int *ipctl_vars[IPCTL_MAXID] = IPCTL_VARS;
-struct niqueue ipintrq = NIQUEUE_INITIALIZER(IFQ_MAXLEN, NETISR_IP);
+struct niqueue ipintrq = NIQUEUE_INITIALIZER(IPQ_MAXLEN, NETISR_IP);
struct pool ipqent_pool;
struct pool ipq_pool;