io_uring: clear req->result on IOPOLL re-issue
authorJens Axboe <axboe@kernel.dk>
Thu, 27 Aug 2020 00:58:26 +0000 (18:58 -0600)
committerJens Axboe <axboe@kernel.dk>
Thu, 27 Aug 2020 01:37:13 +0000 (19:37 -0600)
commit84fa6532477f61d8cfc4b8a6f5ea6f254345367b
treea2d9dc8a44115cddd4f457e918fbe44e0eec1a4a
parentb5ddc6a9b603eb4588e885b03e565e5df1d0a09d
io_uring: clear req->result on IOPOLL re-issue

Make sure we clear req->result, which was set to -EAGAIN for retry
purposes, when moving it to the reissue list. Otherwise we can end up
retrying a request more than once, which leads to weird results in
the io-wq handling (and other spots).

Cc: stable@vger.kernel.org
Reported-by: Andres Freund <andres@anarazel.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c