io_uring: cache poll/double-poll state with a request flag
authorJens Axboe <axboe@kernel.dk>
Wed, 16 Mar 2022 22:59:10 +0000 (16:59 -0600)
committerJens Axboe <axboe@kernel.dk>
Wed, 16 Mar 2022 22:59:10 +0000 (16:59 -0600)
commit91eac1c69c202d9dad8bf717ae5b92db70bfe5cf
tree2374bab1fc136050c6b35c3db0cbe78065158138
parent81459350d581e958ee9c6e76031f77333881c23c
io_uring: cache poll/double-poll state with a request flag

With commit "io_uring: cache req->apoll->events in req->cflags" applied,
we now have just io_poll_remove_entries() dipping into req->apoll when
it isn't strictly necessary.

Mark poll and double-poll with a flag, so we know if we need to look
at apoll->double_poll. This avoids pulling in those cachelines if we
don't need them. The common case is that the poll wake handler already
removed these entries while hot off the completion path.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
fs/io_uring.c