Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Jul 1996 12:38:25 -0700 (PDT)
From:      "JULIAN Elischer" <julian@ref.tfs.com>
To:        wollman@freefall.freebsd.org (Garrett Wollman)
Cc:        CVS-committers@freefall.freebsd.org, cvs-all@freefall.freebsd.org, cvs-sys@freefall.freebsd.org
Subject:   Re: cvs commit:  src/sys/sys protosw.h src/sys/kern uipc_domain.c uipc_socket2.c
Message-ID:  <199607091938.MAA16141@ref.tfs.com>
In-Reply-To: <199607091912.MAA29031@freefall.freebsd.org> from "Garrett Wollman" at Jul 9, 96 12:12:57 pm

next in thread | previous in thread | raw e-mail | index | archive | help
 well as the maintainer of a proprietary protocol stack,
 which is shared between 4 differnt operating systems
 (FreeBSD, BSD4.3/VME-68030, MACH2.5/at386 , and OSF/1-386)
 I can't say that I'm thrilled if suddenly I need to throw away 
 the compatibility between theae OS's in this area.
 the protocol stacks have a usrreq() entry and that works fine..
 of course if you were to backport your changes to 4.3 and OSF1 and MACH
 it'd make me a lot happier, but somehow I don't think that this will happen.

It also makes us totally incompatible with the stevens books and the 4.4
book in this regard.. I think it should probably been done this way to start
with, but memory was tighter then, I think this will result
in more text bytes. 

Also I guess I need to go look at the protocols I'm about to commit
to see if it affects them

More comments whan I've looke at it some more..

personally I think there'd be more savings by making a socket be a vnode
with socket-fs type private data..


> 
> 
> wollman     96/07/09 12:12:56
> 
>   Modified:    sys/sys   protosw.h
>                sys/kern  uipc_domain.c uipc_socket2.c
>   Log:
>   This is a proposal-in-code for a substantial modification of the way
>   the high kernel calls into a protocol stack to perform requests on the
>   user's behalf.  We replace the pr_usrreq() entry in struct protosw with a
>   pointer to a structure containing pointers to functions which implement
>   the various reuqests; each function is declared with the correct type and
>   number of arguments.  (This is unlike the current scheme in which a quarter
>   of the requests take arguments of type other than (struct mbuf *) and the
>   difference is papered over with casts.)  There are a few benefits to this
>   new scheme:
>   
>   1) Arguments are passed with their correct types, and null-pointer dummies
>      are no longer necessary.
>   
>   2) There should be slightly better caching effects from eliminating
>      the prximity to extraneous code and th switch in pr_usrreq().
>   
>   3) It becomes much easier to change the types of the arguments to something
>      other than `struct mbuf *' (e.g.,pushing the work of sosend() into
>      the protocol as advocated by Van Jacobson).
>   
>   There is one principal drawback: existing protocol stacks need to
>   be modified.  This is alleviated by compatibility code in
>   uipc_socket2.c and uipc_domain.c which emulates the new interface
>   in terms of the old and vice versa.
>   
>   This idea is not original to me.  I  read about what Jacobson did
>   in one of his papers and have tried to implement  the first steps
>   towards something like that here.  Much work remains to be done.
>   
>   Revision  Changes    Path
>   1.10      +52 -1     src/sys/sys/protosw.h
>   1.13      +10 -2     src/sys/kern/uipc_domain.c
>   1.11      +219 -1    src/sys/kern/uipc_socket2.c
> 




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199607091938.MAA16141>