History

io_uring: add support for recvmsg()

This is done through IORING_OP_RECVMSG. This opcode uses the same sqe->msg_flags that IORING_OP_SENDMSG added, and we pass in the msghdr struct in the sqe->addr field as well. We use MSG_DONTWAIT to force an inline fast path if recvmsg() doesn't block, and punt to async execution if it would have.

Jens Axboe committed 7 years ago

Commit aa1fa281 parent 0fa03c64 files · +39 −4Browse files

Showing the changes to include/uapi/linux (1 of 4 files). Show all

Unified · Split

include/uapi/linux/io_uring.h+1−0
@@ -60,6 +60,7 @@ struct io_uring_sqe { · 59 unmodified lines
60#define IORING_OP_POLL_REMOVE 760#define IORING_OP_POLL_REMOVE 7
61#define IORING_OP_SYNC_FILE_RANGE 861#define IORING_OP_SYNC_FILE_RANGE 8
62#define IORING_OP_SENDMSG 962#define IORING_OP_SENDMSG 9
63#define IORING_OP_RECVMSG 10
63 64
64/*65/*
65 * sqe->fsync_flags66 * sqe->fsync_flags