freebsd-skq/sys/netkey
rwatson 720efebbba Change semantics of socket close and detach. Add a new protocol switch
function, pru_close, to notify protocols that the file descriptor or
other consumer of a socket is closing the socket.  pru_abort is now a
notification of close also, and no longer detaches.  pru_detach is no
longer used to notify of close, and will be called during socket
tear-down by sofree() when all references to a socket evaporate after
an earlier call to abort or close the socket.  This means detach is now
an unconditional teardown of a socket, whereas previously sockets could
persist after detach of the protocol retained a reference.

This faciliates sharing mutexes between layers of the network stack as
the mutex is required during the checking and removal of references at
the head of sofree().  With this change, pru_detach can now assume that
the mutex will no longer be required by the socket layer after
completion, whereas before this was not necessarily true.

Reviewed by:	gnn
2006-07-21 17:11:15 +00:00
..
key_debug.c Fix -Wundef from compiling the amd64 LINT. 2005-12-04 10:06:06 +00:00
key_debug.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
key_var.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
key.c SADB_UPDATE did not return an error when key length is invalid. 2005-08-22 07:05:14 +00:00
key.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
keydb.c Normalize a significant number of kernel malloc type names: 2005-10-31 15:41:29 +00:00
keydb.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
keysock.c Change semantics of socket close and detach. Add a new protocol switch 2006-07-21 17:11:15 +00:00
keysock.h Fix stack corruptions on amd64. 2006-01-21 10:44:34 +00:00