The branch main has been updated by glebius:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=b925d719678210b76adeb105f5f4b41550eb6bb4

commit b925d719678210b76adeb105f5f4b41550eb6bb4
Author:     Gleb Smirnoff <[email protected]>
AuthorDate: 2024-05-07 21:15:49 +0000
Commit:     Gleb Smirnoff <[email protected]>
CommitDate: 2024-05-07 21:15:49 +0000

    sockets: garbage collect PRCOREQUESTS and stale comment
    
    The code deleted predates FreeBSD history.  The comment deleted is 99%
    outdated.  Why KAME decided to use these constants instead of normal ones
    also lost in centuries.
---
 sys/netinet6/icmp6.c |  4 ++--
 sys/sys/protosw.h    | 24 ------------------------
 2 files changed, 2 insertions(+), 26 deletions(-)

diff --git a/sys/netinet6/icmp6.c b/sys/netinet6/icmp6.c
index c5e3334eca67..e0f642544327 100644
--- a/sys/netinet6/icmp6.c
+++ b/sys/netinet6/icmp6.c
@@ -2683,7 +2683,7 @@ icmp6_ctloutput(struct socket *so, struct sockopt *sopt)
        }
 
        switch (op) {
-       case PRCO_SETOPT:
+       case SOPT_SET:
                switch (optname) {
                case ICMP6_FILTER:
                    {
@@ -2708,7 +2708,7 @@ icmp6_ctloutput(struct socket *so, struct sockopt *sopt)
                }
                break;
 
-       case PRCO_GETOPT:
+       case SOPT_GET:
                switch (optname) {
                case ICMP6_FILTER:
                    {
diff --git a/sys/sys/protosw.h b/sys/sys/protosw.h
index 60d8ffc31362..1d691166929f 100644
--- a/sys/sys/protosw.h
+++ b/sys/sys/protosw.h
@@ -163,30 +163,6 @@ struct protosw {
 #define        PR_CAPATTACH    0x80            /* socket can attach in cap 
mode */
 #define        PR_SOCKBUF      0x100           /* private implementation of 
buffers */
 
-/*
- * The arguments to ctloutput are:
- *     (*protosw[].pr_ctloutput)(req, so, level, optname, optval, p);
- * req is one of the actions listed below, so is a (struct socket *),
- * level is an indication of which protocol layer the option is intended.
- * optname is a protocol dependent socket option request,
- * optval is a pointer to a mbuf-chain pointer, for value-return results.
- * The protocol is responsible for disposal of the mbuf chain *optval
- * if supplied,
- * the caller is responsible for any space held by *optval, when returned.
- * A non-zero return from ctloutput gives an
- * UNIX error number which should be passed to higher level software.
- */
-#define        PRCO_GETOPT     0
-#define        PRCO_SETOPT     1
-
-#define        PRCO_NCMDS      2
-
-#ifdef PRCOREQUESTS
-char   *prcorequests[] = {
-       "GETOPT", "SETOPT",
-};
-#endif
-
 #ifdef _KERNEL
 struct domain *pffinddomain(int family);
 struct protosw *pffindproto(int family, int type, int proto);

Reply via email to