diff options
-rw-r--r-- | sys/sys/protosw.h | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/sys/sys/protosw.h b/sys/sys/protosw.h index 88d3580..9f064c5 100644 --- a/sys/sys/protosw.h +++ b/sys/sys/protosw.h @@ -66,9 +66,7 @@ struct sockopt; /* USE THESE FOR YOUR PROTOTYPES ! */ typedef void pr_input_t (struct mbuf *, int); typedef int pr_input6_t (struct mbuf **, int*, int); /* XXX FIX THIS */ -typedef void pr_in_input_t (struct mbuf *, int, int); /* XXX FIX THIS */ typedef int pr_output_t (struct mbuf *, struct socket *); -typedef int pr_in_output_t (struct mbuf *, struct socket *, struct sockaddr *); typedef void pr_ctlinput_t (int, struct sockaddr *, void *); typedef int pr_ctloutput_t (struct socket *, struct sockopt *); typedef void pr_init_t (void); @@ -76,9 +74,6 @@ typedef void pr_fasttimo_t (void); typedef void pr_slowtimo_t (void); typedef void pr_drain_t (void); -typedef int pr_usrreq_t(struct socket *, int, struct mbuf *, - struct mbuf *, struct mbuf *, struct thread *); - struct protosw { short pr_type; /* socket type used for */ struct domain *pr_domain; /* domain protocol a member of */ @@ -95,7 +90,7 @@ struct protosw { pr_slowtimo_t *pr_slowtimo; /* slow timeout (500ms) */ pr_drain_t *pr_drain; /* flush any excess space possible */ - struct pr_usrreqs *pr_usrreqs; /* supersedes pr_usrreq() */ + struct pr_usrreqs *pr_usrreqs; /* user-protocol hook */ }; /*#endif*/ @@ -131,17 +126,6 @@ struct protosw { * We now provide individual function pointers which protocols can implement, * which offers a number of benefits (such as type checking for arguments). * These older constants are still present in order to support TCP debugging. - * - * The arguments to usrreq were: - * (*protosw[].pr_usrreq)(up, req, m, nam, opt); - * where up is a (struct socket *), req is one of these requests, - * m is an optional mbuf chain containing a message, - * nam is an optional mbuf chain containing an address, - * and opt is a pointer to a socketopt structure or nil. - * The protocol is responsible for disposal of the mbuf chain m, - * the caller is responsible for any space held by nam and opt. - * A non-zero return from usrreq gives an - * UNIX error number which should be passed to higher level software. */ #define PRU_ATTACH 0 /* attach protocol to up */ #define PRU_DETACH 1 /* detach protocol from up */ @@ -170,8 +154,8 @@ struct protosw { #define PRU_SEND_EOF 22 /* send and close */ #define PRU_SOSETLABEL 23 /* MAC label change */ #define PRU_CLOSE 24 /* socket close */ -#define PRU_FLUSH 25 /* flush the socket */ -#define PRU_NREQ 25 +#define PRU_FLUSH 25 /* flush the socket */ +#define PRU_NREQ 25 #ifdef PRUREQUESTS const char *prurequests[] = { @@ -181,7 +165,7 @@ const char *prurequests[] = { "SENSE", "RCVOOB", "SENDOOB", "SOCKADDR", "PEERADDR", "CONNECT2", "FASTTIMO", "SLOWTIMO", "PROTORCV", "PROTOSEND", "SEND_EOF", "SOSETLABEL", - "CLOSE", "FLUSH", + "CLOSE", "FLUSH", }; #endif @@ -327,7 +311,7 @@ char *prcrequests[] = { * 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 usrreq gives an + * A non-zero return from ctloutput gives an * UNIX error number which should be passed to higher level software. */ #define PRCO_GETOPT 0 |