Update comments in struct protosw to reflect changing times:

- Between 1996 and 1997, wollman eliminated pr_usrreq() and replaced it
  with direct function pointers.  Update comment to reflect these changes.

- In 2003, I added pru_sosetlabel().  Update comment to reflect this
  change.

MFC after:	1 week
This commit is contained in:
Robert Watson 2006-06-07 13:09:04 +00:00
parent b96baf0a65
commit 6fbb9cf860
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=159374

View File

@ -128,7 +128,13 @@ struct protosw {
#define PR_LASTHDR 0x40 /* enforce ipsec policy; last header */
/*
* The arguments to usrreq are:
* In earlier BSD network stacks, a single pr_usrreq() function pointer was
* invoked with an operation number indicating what operation was desired.
* 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,
@ -186,10 +192,8 @@ struct ucred;
struct uio;
/*
* If the ordering here looks odd, that's because it's alphabetical.
* Having this structure separated out from the main protoswitch is allegedly
* a big (12 cycles per call) lose on high-end CPUs. We will eventually
* migrate this stuff back into the main structure.
* If the ordering here looks odd, that's because it's alphabetical. These
* should eventually be merged back into struct protosw.
*
* Some fields initialized to defaults if they are NULL.
* See uipc_domain.c:net_init_domain()
@ -224,7 +228,7 @@ struct pr_usrreqs {
int (*pru_sockaddr)(struct socket *so, struct sockaddr **nam);
/*
* These three added later, so they are out of order. They are used
* These four added later, so they are out of order. They are used
* for shortcutting (fast path input/output) in some protocols.
* XXX - that's a lie, they are not implemented yet
* Rather than calling sosend() etc. directly, calls are made