summaryrefslogtreecommitdiff
path: root/io_uring
diff options
context:
space:
mode:
authorPavel Begunkov <asml.silence@gmail.com>2022-08-18 14:38:34 +0300
committerJens Axboe <axboe@kernel.dk>2022-08-18 16:27:20 +0300
commit3f743e9bbb8fe20f4c477e4bf6341c4187a4a264 (patch)
tree6ccc56e361aac3abe0badfb88d0708ca00968106 /io_uring
parent5993000dc6b31b927403cee65fbc5f9f070fa3e4 (diff)
downloadlinux-3f743e9bbb8fe20f4c477e4bf6341c4187a4a264.tar.xz
io_uring/net: use right helpers for async_data
There is another spot where we check ->async_data directly instead of using req_has_async_data(), which is the way to do it, fix it up. Fixes: 43e0bbbd0b0e3 ("io_uring: add netmsg cache") Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Link: https://lore.kernel.org/r/42f33b9a81dd6ae65dda92f0372b0ff82d548517.1660822636.git.asml.silence@gmail.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'io_uring')
-rw-r--r--io_uring/net.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/io_uring/net.c b/io_uring/net.c
index f7cbd716817f..f8cdf1dc3863 100644
--- a/io_uring/net.c
+++ b/io_uring/net.c
@@ -152,9 +152,9 @@ static int io_setup_async_msg(struct io_kiocb *req,
struct io_async_msghdr *kmsg,
unsigned int issue_flags)
{
- struct io_async_msghdr *async_msg = req->async_data;
+ struct io_async_msghdr *async_msg;
- if (async_msg)
+ if (req_has_async_data(req))
return -EAGAIN;
async_msg = io_recvmsg_alloc_async(req, issue_flags);
if (!async_msg) {