io_uring/poll: introduce io_arm_apoll()
authorPavel Begunkov <asml.silence@gmail.com>
Mon, 16 Jun 2025 09:46:26 +0000 (10:46 +0100)
committerJens Axboe <axboe@kernel.dk>
Mon, 23 Jun 2025 15:00:12 +0000 (09:00 -0600)
commit162151889267089bb920609830c35f9272087c3f
treee1a7682585ba9c733bb9d57cf91bed15be66d3cb
parent5be5726e1a237cb3c2dfa39cb3edcaa4512664df
io_uring/poll: introduce io_arm_apoll()

In preparation to allowing commands to do file polling, add a helper
that takes the desired poll event mask and arms it for polling. We won't
be able to use io_arm_poll_handler() with IORING_OP_URING_CMD as it
tries to infer the mask from the opcode data, and we can't unify it
across all commands.

Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Link: https://lore.kernel.org/r/7ee5633f2dc45fd15243f1a60965f7e30e1c48e8.1750065793.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
io_uring/poll.c
io_uring/poll.h