From: Dmitrii Bundin <dmitrii.bundin.a@gmail.com>
To: axboe@kernel.dk, asml.silence@gmail.com
Cc: io-uring@vger.kernel.org, linux-kernel@vger.kernel.org,
Dmitrii Bundin <dmitrii.bundin.a@gmail.com>
Subject: [PATCH] io_uring: remove excessive unlikely on IS_ERR
Date: Mon, 9 Jan 2023 21:58:54 +0300 [thread overview]
Message-ID: <20230109185854.25698-1-dmitrii.bundin.a@gmail.com> (raw)
The IS_ERR function uses the IS_ERR_VALUE macro under the hood which
already wraps the condition into unlikely.
Signed-off-by: Dmitrii Bundin <dmitrii.bundin.a@gmail.com>
---
io_uring/rw.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/io_uring/rw.c b/io_uring/rw.c
index 8227af2e1c0f..27d5e3323a53 100644
--- a/io_uring/rw.c
+++ b/io_uring/rw.c
@@ -410,7 +410,7 @@ static inline int io_import_iovec(int rw, struct io_kiocb *req,
unsigned int issue_flags)
{
*iovec = __io_import_iovec(rw, req, s, issue_flags);
- if (unlikely(IS_ERR(*iovec)))
+ if (IS_ERR(*iovec))
return PTR_ERR(*iovec);
iov_iter_save_state(&s->iter, &s->iter_state);
--
2.17.1
next reply other threads:[~2023-01-09 18:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-09 18:58 Dmitrii Bundin [this message]
2023-01-09 23:14 ` 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=20230109185854.25698-1-dmitrii.bundin.a@gmail.com \
--to=dmitrii.bundin.a@gmail.com \
--cc=asml.silence@gmail.com \
--cc=axboe@kernel.dk \
--cc=io-uring@vger.kernel.org \
--cc=linux-kernel@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
all inboxes | Powered by JetHome®