From: Pavel Begunkov <asml.silence@gmail.com>
To: io-uring@vger.kernel.org
Cc: asml.silence@gmail.com
Subject: [PATCH 3/3] io_uring/rsrc: remove null check on import
Date: Sat, 19 Apr 2025 18:47:06 +0100 [thread overview]
Message-ID: <3782c01e311dbd474bca45aefaf79a2f2822fafb.1745083025.git.asml.silence@gmail.com> (raw)
In-Reply-To: <cover.1745083025.git.asml.silence@gmail.com>
WARN_ON_ONCE() checking imu for NULL in io_import_fixed() is in the hot
path and too protective, it's time to get rid of it.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
---
io_uring/rsrc.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/io_uring/rsrc.c b/io_uring/rsrc.c
index 21613e6074d4..b2b9053b31c7 100644
--- a/io_uring/rsrc.c
+++ b/io_uring/rsrc.c
@@ -1058,8 +1058,6 @@ static int io_import_fixed(int ddir, struct iov_iter *iter,
size_t offset;
int ret;
- if (WARN_ON_ONCE(!imu))
- return -EFAULT;
ret = validate_fixed_range(buf_addr, len, imu);
if (unlikely(ret))
return ret;
--
2.48.1
next prev parent reply other threads:[~2025-04-19 17:46 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-19 17:47 [PATCH 0/3] registrered buffer coalescing cleanup Pavel Begunkov
2025-04-19 17:47 ` [PATCH 1/3] io_uring/rsrc: use unpin_user_folio Pavel Begunkov
2025-04-21 2:37 ` Anuj gupta
2025-04-19 17:47 ` [PATCH 2/3] io_uring/rsrc: clean up io_coalesce_buffer() Pavel Begunkov
2025-04-21 2:38 ` Anuj gupta
[not found] ` <CGME20250421115925epcas5p18c9a46be72b98c089dc1833befc4d06d@epcas5p1.samsung.com>
2025-04-21 11:50 ` Nitesh Shetty
2025-04-21 14:50 ` Jens Axboe
2025-04-19 17:47 ` Pavel Begunkov [this message]
2025-04-21 11:13 ` [PATCH 0/3] registrered buffer coalescing cleanup Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3782c01e311dbd474bca45aefaf79a2f2822fafb.1745083025.git.asml.silence@gmail.com \
--to=asml.silence@gmail.com \
--cc=io-uring@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox