Split out handlers for SOCK_DGRAM unix(4) sockets from SOCK_STREAM and
authormvs <mvs@openbsd.org>
Sun, 13 Nov 2022 16:01:32 +0000 (16:01 +0000)
committermvs <mvs@openbsd.org>
Sun, 13 Nov 2022 16:01:32 +0000 (16:01 +0000)
commit67a10ba2366df7017b776ada734f425cd14cc7b0
tree64ca8bf0577841c0710aa90f21d297d061f27208
parentdc792f329092b549f5918163cb30c2f1d7dd088f
Split out handlers for SOCK_DGRAM unix(4) sockets from SOCK_STREAM and
SOCK_SEQPACKET. Introduce `uipc_dgram_usrreqs' to store pointers for
dgram specific handlers.

The dgram pru_shutdown and pru_send handlers were splitted to
uipc_dgram_shutdown() and uipc_dgram_send(). The pru_accept, pru_rcvd
and pru_abort handlers are not required for dgram sockets.

The unp_disconnect() remains shared between all unix(4) sockets because
it called from common paths too.

Proposed by and ok guenther@
sys/kern/uipc_proto.c
sys/kern/uipc_usrreq.c
sys/sys/unpcb.h