diff options
author | wollman <wollman@FreeBSD.org> | 1995-11-01 17:18:27 +0000 |
---|---|---|
committer | wollman <wollman@FreeBSD.org> | 1995-11-01 17:18:27 +0000 |
commit | c53e4d30eddfc89be2cd81c9c3ea3a595789fdc2 (patch) | |
tree | 4a4587ac814c1bb0291d9e880f9c5a4164437d38 /sys/netinet | |
parent | 16af6306ac9c39e9287fb9c48c3f74cb990335d2 (diff) | |
download | FreeBSD-src-c53e4d30eddfc89be2cd81c9c3ea3a595789fdc2.zip FreeBSD-src-c53e4d30eddfc89be2cd81c9c3ea3a595789fdc2.tar.gz |
Instrument the IP input queue with two new read-only MIB entries:
net.inet.ip.intr-queue-maxlen (=== ipintrq.ifq_maxlen)
and net.inet.ip.intr-queue-drops (=== ipintrq.ifq_drops)
There should probably be a standard way of getting the same information
going the other way.
Diffstat (limited to 'sys/netinet')
-rw-r--r-- | sys/netinet/in.h | 8 | ||||
-rw-r--r-- | sys/netinet/ip_input.c | 7 |
2 files changed, 12 insertions, 3 deletions
diff --git a/sys/netinet/in.h b/sys/netinet/in.h index 53fd103..09e5bc9 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.10 1995/06/13 17:51:08 wollman Exp $ + * $Id: in.h,v 1.11 1995/07/18 09:56:42 peter Exp $ */ #ifndef _NETINET_IN_H_ @@ -233,7 +233,9 @@ struct ip_mreq { #define IPCTL_RTMAXCACHE 7 /* trigger level for dynamic expire */ #define IPCTL_SOURCEROUTE 8 /* may perform source routes */ #define IPCTL_DIRECTEDBROADCAST 9 /* may re-broadcast received packets */ -#define IPCTL_MAXID 10 +#define IPCTL_INTRQMAXLEN 10 /* max length of netisr queue */ +#define IPCTL_INTRQDROPS 11 /* number of netisr q drops */ +#define IPCTL_MAXID 12 #define IPCTL_NAMES { \ { 0, 0 }, \ @@ -246,6 +248,8 @@ struct ip_mreq { { "rtmaxcache", CTLTYPE_INT }, \ { "sourceroute", CTLTYPE_INT }, \ { "directed-broadcast", CTLTYPE_INT }, \ + { "intr-queue-maxlen", CTLTYPE_INT }, \ + { "intr-queue-drops", CTLTYPE_INT }, \ } diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c index b514ca7..383573b 100644 --- a/sys/netinet/ip_input.c +++ b/sys/netinet/ip_input.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)ip_input.c 8.2 (Berkeley) 1/4/94 - * $Id: ip_input.c,v 1.25 1995/07/09 14:29:46 davidg Exp $ + * $Id: ip_input.c,v 1.26 1995/07/18 09:56:44 peter Exp $ */ #include <sys/param.h> @@ -1228,6 +1228,11 @@ ip_sysctl(name, namelen, oldp, oldlenp, newp, newlen) case IPCTL_RTMAXCACHE: return (sysctl_int(oldp, oldlenp, newp, newlen, &rtq_toomany)); + case IPCTL_INTRQMAXLEN: + return (sysctl_rdint(oldp, oldlenp, newp, + ipintrq.ifq_maxlen)); + case IPCTL_INTRQDROPS: + return (sysctl_rdint(oldp, oldlenp, newp, ipintrq.ifq_drops)); default: return (EOPNOTSUPP); } |