summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in.h
diff options
context:
space:
mode:
authorwollman <wollman@FreeBSD.org>1995-02-14 23:04:52 +0000
committerwollman <wollman@FreeBSD.org>1995-02-14 23:04:52 +0000
commite3defa4503d0fce9ea8650a9557e03073e3aef45 (patch)
tree8c512b48a982f2c32fad6db890c8d4e3c0ebb9a6 /sys/netinet/in.h
parent0044192fdf92b0b40aa3c4f34cb2078b1d6a4747 (diff)
downloadFreeBSD-src-e3defa4503d0fce9ea8650a9557e03073e3aef45.zip
FreeBSD-src-e3defa4503d0fce9ea8650a9557e03073e3aef45.tar.gz
Attempt to make the host route cache a bit smarter under conditions of
high load: 1) If there ever get to be more than net.inet.ip.rtmaxcache entries in the cache, in_rtqtimo() will reduce net.inet.ip.rtexpire by 1/3 and do another round, unles net.inet.ip.rtexpire is less than net.inet.ip.rtminexpire, and never more than once in ten minutes (rtq_timeout). 2) If net.inet.ip.rtexpire is set to zero, don't bother to cache anything.
Diffstat (limited to 'sys/netinet/in.h')
-rw-r--r--sys/netinet/in.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/netinet/in.h b/sys/netinet/in.h
index 3164a09..b4fd19f 100644
--- a/sys/netinet/in.h
+++ b/sys/netinet/in.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in.h 8.3 (Berkeley) 1/3/94
- * $Id: in.h,v 1.5 1994/12/14 19:06:36 wollman Exp $
+ * $Id: in.h,v 1.6 1994/12/21 17:23:59 wollman Exp $
*/
#ifndef _NETINET_IN_H_
@@ -227,7 +227,9 @@ struct ip_mreq {
#define IPCTL_DEFMTU 4 /* default MTU */
#endif
#define IPCTL_RTEXPIRE 5 /* cloned route expiration time */
-#define IPCTL_MAXID 6
+#define IPCTL_RTMINEXPIRE 6 /* min value for expiration time */
+#define IPCTL_RTMAXCACHE 7 /* trigger level for dynamic expire */
+#define IPCTL_MAXID 8
#define IPCTL_NAMES { \
{ 0, 0 }, \
@@ -236,6 +238,8 @@ struct ip_mreq {
{ "ttl", CTLTYPE_INT }, \
{ "mtu", CTLTYPE_INT }, \
{ "rtexpire", CTLTYPE_INT }, \
+ { "rtminexpire", CTLTYPE_INT }, \
+ { "rtmaxcache", CTLTYPE_INT }, \
}
OpenPOWER on IntegriCloud