Commit aacf2f9
io_uring: fix req->apoll_events
apoll_events should be set once in the beginning of poll arming just as
poll->events and not change after. However, currently io_uring resets it
on each __io_poll_execute() for no clear reason. There is also a place
in __io_arm_poll_handler() where we add EPOLLONESHOT to downgrade a
multishot, but forget to do the same thing with ->apoll_events, which is
buggy.
Fixes: 8145935 ("io_uring: cache req->apoll->events in req->cflags")
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Reviewed-by: Hao Xu <howeyxu@tencent.com>
Link: https://lore.kernel.org/r/0aef40399ba75b1a4d2c2e85e6e8fd93c02fc6e4.1655814213.git.asml.silence@gmail.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>1 parent b60cac1 commit aacf2f9
1 file changed
Lines changed: 8 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6950 | 6950 | | |
6951 | 6951 | | |
6952 | 6952 | | |
6953 | | - | |
| 6953 | + | |
| 6954 | + | |
6954 | 6955 | | |
6955 | 6956 | | |
6956 | 6957 | | |
| |||
6959 | 6960 | | |
6960 | 6961 | | |
6961 | 6962 | | |
6962 | | - | |
6963 | 6963 | | |
6964 | 6964 | | |
6965 | 6965 | | |
| |||
7110 | 7110 | | |
7111 | 7111 | | |
7112 | 7112 | | |
| 7113 | + | |
| 7114 | + | |
7113 | 7115 | | |
7114 | 7116 | | |
7115 | 7117 | | |
| |||
7140 | 7142 | | |
7141 | 7143 | | |
7142 | 7144 | | |
7143 | | - | |
| 7145 | + | |
7144 | 7146 | | |
| 7147 | + | |
| 7148 | + | |
7145 | 7149 | | |
7146 | 7150 | | |
7147 | 7151 | | |
| |||
7388 | 7392 | | |
7389 | 7393 | | |
7390 | 7394 | | |
7391 | | - | |
| 7395 | + | |
7392 | 7396 | | |
7393 | 7397 | | |
7394 | 7398 | | |
| |||
0 commit comments