git: 55543349168a - stable/12 - ipfilter: Remove unused ioctl
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 11 Sep 2022 12:38:23 UTC
The branch stable/12 has been updated by cy: URL: https://cgit.FreeBSD.org/src/commit/?id=55543349168a193e0f2ab4375e90845af9a64d59 commit 55543349168a193e0f2ab4375e90845af9a64d59 Author: Cy Schubert <cy@FreeBSD.org> AuthorDate: 2022-09-06 20:58:35 +0000 Commit: Cy Schubert <cy@FreeBSD.org> CommitDate: 2022-09-11 12:37:50 +0000 ipfilter: Remove unused ioctl The SIOCSTAT1 ioctl is only used in ip_auth and is unused in ip_state. The ip_state version was likely added to support a new statistic yet to be developed in ipfstat(8) or for some sample userspace application (similar in fashion to the sample provided for authentication rules). There is no need to report individual state hash table bucket lengths to any future userspace application. If needed for any future debugging purposes a DTrace probe would be a better vehicle. This unused ioctl in ip_stat results in a panic. PR: 266124 Reported by: Robert Morris <rtm@lcs.mit.edu> (cherry picked from commit 1f7a710ab35845049f17958c3783041c214d8a3c) --- sys/netpfil/ipfilter/netinet/ip_state.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/sys/netpfil/ipfilter/netinet/ip_state.c b/sys/netpfil/ipfilter/netinet/ip_state.c index cc0e8559fb16..463416f454a9 100644 --- a/sys/netpfil/ipfilter/netinet/ip_state.c +++ b/sys/netpfil/ipfilter/netinet/ip_state.c @@ -751,18 +751,6 @@ ipf_state_ioctl(ipf_main_softc_t *softc, caddr_t data, ioctlcmd_t cmd, error = ipf_state_getent(softc, softs, data); break; - /* - * Return a copy of the hash table bucket lengths - */ - case SIOCSTAT1 : - error = BCOPYOUT(softs->ipf_state_stats.iss_bucketlen, data, - softs->ipf_state_size * sizeof(u_int)); - if (error != 0) { - IPFERROR(100017); - error = EFAULT; - } - break; - case SIOCGENITER : { ipftoken_t *token;