Skip to content

Add support for no-lock sockets

Jens Axboe io-uring netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 13 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4net: add sock 'sk_no_lock' memberinclude/net/sock.h net/core/sock.c+4 -00 replies
2/4net: allow sk_prot->release_cb() without sock lock heldinclude/net/sock.h net/atm/common.c net/ipv4/tcp_output.c +2 more+21 -10 replies
3/4net: add support for socket no-lockinclude/net/sock.h net/core/sock.c+39 -20 replies
4/4io_uring: mark accept direct socket as no-lockfs/io_uring.c+46 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCHSET 0/4] Add support for no-lock sockets

Hi,

If we accept a connection directly, eg without installing a file descriptor for it, or if we use IORING_OP_SOCKET in direct mode, then we have a socket for recv/send that we can fully serialize access to.

With that in mind, we can feasibly skip locking on the socket for TCP in that case. Some of the testing I've done has shown as much as 15% of overhead in the lock_sock/release_sock part, with this change then we see none.

Comments welcome!

Signature · 1 line
Jens Axboe