summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2022-05-18 10:40:03 +0200
committerJens Axboe <axboe@kernel.dk>2022-05-18 06:19:05 -0600
commit58f5c8d39e0ea07fdaaea6a85c49000da83dc0cc (patch)
tree419fe3ceaba24fa2d8ac92bd19822a3104984129
parentee67ba3b20f7dcd001b7743eb8e46880cb27fdc6 (diff)
downloadlinux-58f5c8d39e0ea07fdaaea6a85c49000da83dc0cc.tar.bz2
io_uring: make apoll_events a __poll_t
apoll_events is fed to vfs_poll and the poll tables, so it should be a __poll_t. Signed-off-by: Christoph Hellwig <hch@lst.de> Link: https://lore.kernel.org/r/20220518084005.3255380-5-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r--fs/io_uring.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/io_uring.c b/fs/io_uring.c
index 0b1e10d5fbd2..c4214bfc7039 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -1011,7 +1011,7 @@ struct io_kiocb {
/* used by request caches, completion batching and iopoll */
struct io_wq_work_node comp_list;
/* cache ->apoll->events */
- int apoll_events;
+ __poll_t apoll_events;
};
atomic_t refs;
atomic_t poll_refs;
@@ -6297,7 +6297,7 @@ static void io_apoll_task_func(struct io_kiocb *req, bool *locked)
io_req_complete_failed(req, ret);
}
-static void __io_poll_execute(struct io_kiocb *req, int mask, int events)
+static void __io_poll_execute(struct io_kiocb *req, int mask, __poll_t events)
{
req->cqe.res = mask;
/*
@@ -6316,7 +6316,8 @@ static void __io_poll_execute(struct io_kiocb *req, int mask, int events)
io_req_task_work_add(req, false);
}
-static inline void io_poll_execute(struct io_kiocb *req, int res, int events)
+static inline void io_poll_execute(struct io_kiocb *req, int res,
+ __poll_t events)
{
if (io_poll_get_ownership(req))
__io_poll_execute(req, res, events);