[PATCH v2 0/2] io_uring/net: support registered buffer for plain send and recv
Ming Lei <[email protected]>
| Newsgroups | org.kernel.vger.io-uring |
|---|---|
| Message-ID | <[email protected]> |
From: Ming Lei <[email protected]> Hi, This series wires IORING_RECVSEND_FIXED_BUF into the plain IORING_OP_SEND and IORING_OP_RECV paths; so far the flag has only been honoured on the SEND_ZC path. Motivation: targets such as ublk's NBD backend want to push/pull I/O data directly to/from an io_uring registered buffer over a plain send/recv on a TCP socket, avoiding the per-I/O import and page pinning while keeping single-CQE completion. The SEND_ZC path is left untouched. Patch 1 is the kernel change. Patch 2 adds a liburing test and is meant for the liburing tree. Changes since v1: - Reject IORING_SEND_VECTORIZED on the plain IORING_OP_SEND fixed-buffer path: the plain io_send() issue path imports a single registered buffer and has no vectorized-regbuf import step, so the combination silently did nothing before. (Jens Axboe) - Add the matching send-vectorized negative case to the liburing test. - Clarify in the commit log that SEND_ZC is unaffected. v1: https://lore.kernel.org/io-uring/[email protected]/ Ming Lei (2): io_uring/net: support registered buffer for plain send and recv test: add fixed-buf-send-recv for registered buffer send/recv io_uring/net.c | 47 ++++++- test/Makefile | 1 + test/fixed-buf-send-recv.c | 311 +++++++++++++++++++++++++++++++++++++ 3 files changed, 357 insertions(+), 2 deletions(-) -- 2.54.0