mirror of
https://gitee.com/bianbu-linux/linux-6.6
synced 2025-07-01 23:53:16 -04:00
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. Acked-by: David S. Miller <davem@davemloft.net> Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
0fa03c624d
commit
aa1fa28fc7
4 changed files with 39 additions and 4 deletions
|
@ -378,6 +378,9 @@ extern int __sys_sendmmsg(int fd, struct mmsghdr __user *mmsg,
|
|||
extern long __sys_sendmsg_sock(struct socket *sock,
|
||||
struct user_msghdr __user *msg,
|
||||
unsigned int flags);
|
||||
extern long __sys_recvmsg_sock(struct socket *sock,
|
||||
struct user_msghdr __user *msg,
|
||||
unsigned int flags);
|
||||
|
||||
/* helpers which do the actual work for syscalls */
|
||||
extern int __sys_recvfrom(int fd, void __user *ubuf, size_t size,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue