io_uring: cleanup error-handling around io_req_complete
authorKanchan Joshi <joshi.k@samsung.com>
Fri, 22 Apr 2022 10:10:48 +0000 (15:40 +0530)
committerJens Axboe <axboe@kernel.dk>
Mon, 25 Apr 2022 00:29:33 +0000 (18:29 -0600)
commit4ffaa94b9c047fe0e82b1f271554f31f0e2e2867
tree34aba8c28ce18d4a86fabfbec72860704c4fe916
parent0200ce6a57c5de802f4e438485c14cc9d63d5f4b
io_uring: cleanup error-handling around io_req_complete

Move common error-handling to io_req_complete, so that various callers
avoid repeating that. Few callers (io_tee, io_splice) require slightly
different handling. These are changed to use __io_req_complete instead.

Suggested-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Kanchan Joshi <joshi.k@samsung.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/20220422101048.419942-1-joshi.k@samsung.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c