created | 2025-01-06T20:46:28Z |
---|---|
begin | 2025-01-04T11:45:15Z |
end | 2025-01-04T15:57:02Z |
path | src/sys |
commits | 1 |
date | 2025-01-04T15:57:02Z | |||
---|---|---|---|---|
author | mvs | |||
files | src/sys/kern/uipc_socket.c | log | diff | annotate |
src/sys/netinet/tcp_usrreq.c | log | diff | annotate | |
message |
Relax sockets splicing locking. Sockets splicing works around sockets buffers which have their own locks for all socket types, especially sblock() on `so_snd' which keeps sockets being spliced. - sosplice() does read-only sockets options and state checks, the only modification is `so_sp' assignment. The SB_SPLICE bit modification, `ssp_socket' and `ssp_soback' assignment protected with `sb_mtx' mutex(9). PCB layer does corresponding checks with `sb_mtx' held, so shared solock() is pretty enough in sosplice() path. Introduce special sosplice_solock_pair() for that purpose. - sounsplice() requires shared socket lock only around so{r,w}wakeup calls. - Push exclusive solock() down to tcp(4) case of somove(). Such sockets are not ready do unlocked somove() yet. ok bluhm |