From: Chenliang Li <[email protected]>
To: [email protected], [email protected]
Cc: [email protected], [email protected],
[email protected], [email protected],
[email protected], [email protected],
Chenliang Li <[email protected]>
Subject: [PATCH] io_uring/rsrc: fix incorrect assignment of iter->nr_segs in io_import_fixed
Date: Wed, 19 Jun 2024 14:38:19 +0800 [thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: CGME20240619063825epcas5p26224fc244b0ff14899731dea6d5a674b@epcas5p2.samsung.com
In io_import_fixed when advancing the iter within the first bvec, the
iter->nr_segs is set to bvec->bv_len. nr_segs should be the number of
bvecs, plus we don't need to adjust it here, so just remove it.
Fixes: b000ae0ec2d7 ("io_uring/rsrc: optimise single entry advance")
Signed-off-by: Chenliang Li <[email protected]>
---
io_uring/rsrc.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/io_uring/rsrc.c b/io_uring/rsrc.c
index 60c00144471a..a860516bf448 100644
--- a/io_uring/rsrc.c
+++ b/io_uring/rsrc.c
@@ -1049,7 +1049,6 @@ int io_import_fixed(int ddir, struct iov_iter *iter,
* branch doesn't expect non PAGE_SIZE'd chunks.
*/
iter->bvec = bvec;
- iter->nr_segs = bvec->bv_len;
iter->count -= offset;
iter->iov_offset = offset;
} else {
base-commit: 3b87184f7eff27fef7d7ee18b65f173152e1bb81
--
2.34.1
next parent reply other threads:[~2024-06-19 6:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20240619063825epcas5p26224fc244b0ff14899731dea6d5a674b@epcas5p2.samsung.com>
2024-06-19 6:38 ` Chenliang Li [this message]
2024-06-19 14:27 ` [PATCH] io_uring/rsrc: fix incorrect assignment of iter->nr_segs in io_import_fixed Pavel Begunkov
2024-06-19 15:47 ` Chenliang Li
2024-06-20 10:35 ` Pavel Begunkov
2024-06-20 12:52 ` 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 \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
/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