diff options
author | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2023-04-05 21:51:48 +0000 |
---|---|---|
committer | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2023-04-05 21:51:48 +0000 |
commit | 7e4ccd27cfdfbceb30ea07c53ad747f6dc5095fc (patch) | |
tree | b1bb47b2dfac6571e63243b01f5f308a43b693e1 /sys/netinet/if_ether.c | |
parent | 97d8da8a6b1f8ca43457237826312668a9f2005f (diff) |
ARP has a sysctl to show the number of packets waiting for an arp
response. Implement analog sysctl net.inet6.icmp6.nd6_queued for
ND6 to reduce places where mbufs can hide within the kernel.
Atomic operations operate on unsigned int. Make the type of total
hold queue length consistent.
Use atomic load to read the value for the sysctl. This clarifies
why no lock around sysctl_rdint() is needed.
OK mvs@ kn@
Diffstat (limited to 'sys/netinet/if_ether.c')
-rw-r--r-- | sys/netinet/if_ether.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index b1268d3fa00..46aa3c26acb 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_ether.c,v 1.259 2023/04/05 19:35:23 bluhm Exp $ */ +/* $OpenBSD: if_ether.c,v 1.260 2023/04/05 21:51:47 bluhm Exp $ */ /* $NetBSD: if_ether.c,v 1.31 1996/05/11 12:59:58 mycroft Exp $ */ /* @@ -109,7 +109,7 @@ LIST_HEAD(, llinfo_arp) arp_list = LIST_HEAD_INITIALIZER(arp_list); /* [mN] list of llinfo_arp structures */ struct pool arp_pool; /* [I] pool for llinfo_arp structures */ int arp_maxtries = 5; /* [I] arp requests before set to rejected */ -int la_hold_total; /* [a] packets currently in the arp queue */ +unsigned int la_hold_total; /* [a] packets currently in the arp queue */ #ifdef NFSCLIENT /* revarp state */ |