io_uring: track inflight requests through counter
authorPavel Begunkov <asml.silence@gmail.com>
Sun, 11 Apr 2021 00:46:26 +0000 (01:46 +0100)
committerJens Axboe <axboe@kernel.dk>
Mon, 12 Apr 2021 01:30:41 +0000 (19:30 -0600)
commitb303fe2e5a3802b0b1fb8d997e5c9caef48f6dd8
treec2bae71460051364c63467df6a7bb8aa3ed1ba3a
parent368b2080853f4694db780528c942f191f1c1687c
io_uring: track inflight requests through counter

Instead of keeping requests in a inflight_list, just track them with a
per tctx atomic counter. Apart from it being much easier and more
consistent with task cancel, it frees ->inflight_entry from being shared
between iopoll and cancel-track, so less headache for us.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/3c2ee0863cd7eeefa605f3eaff4c1c461a6f1157.1618101759.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c