public inbox for [email protected]
 help / color / mirror / Atom feed
* [PATCH] io_uring: code clean for kiocb_done()
@ 2021-06-27 21:48 Hao Xu
  2021-06-27 22:23 ` Jens Axboe
  0 siblings, 1 reply; 2+ messages in thread
From: Hao Xu @ 2021-06-27 21:48 UTC (permalink / raw)
  To: Jens Axboe; +Cc: io-uring, Pavel Begunkov, Joseph Qi

A simple code clean for kiocb_done()

Signed-off-by: Hao Xu <[email protected]>
---
 fs/io_uring.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/io_uring.c b/fs/io_uring.c
index 2eb290f68aa3..5280a7bcb68a 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -2801,7 +2801,7 @@ static void kiocb_done(struct kiocb *kiocb, ssize_t ret,
 
 	if (req->flags & REQ_F_CUR_POS)
 		req->file->f_pos = kiocb->ki_pos;
-	if (ret >= 0 && kiocb->ki_complete == io_complete_rw)
+	if (ret >= 0 && check_reissue)
 		__io_complete_rw(req, ret, 0, issue_flags);
 	else
 		io_rw_done(kiocb, ret);
-- 
1.8.3.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] io_uring: code clean for kiocb_done()
  2021-06-27 21:48 [PATCH] io_uring: code clean for kiocb_done() Hao Xu
@ 2021-06-27 22:23 ` Jens Axboe
  0 siblings, 0 replies; 2+ messages in thread
From: Jens Axboe @ 2021-06-27 22:23 UTC (permalink / raw)
  To: Hao Xu; +Cc: io-uring, Pavel Begunkov, Joseph Qi

On 6/27/21 3:48 PM, Hao Xu wrote:
> A simple code clean for kiocb_done()

Obviously correct - applied, thanks.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-06-27 22:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-27 21:48 [PATCH] io_uring: code clean for kiocb_done() Hao Xu
2021-06-27 22:23 ` Jens Axboe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox