projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d99d861
)
aio: Fix incorrect usage of eventfd_signal_allowed()
author
Xie Yongji
<xieyongji@bytedance.com>
Mon, 13 Sep 2021 11:19:28 +0000
(19:19 +0800)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Tue, 14 Dec 2021 09:57:22 +0000
(10:57 +0100)
commit
4b3749865374899e115aa8c48681709b086fe6d3
upstream.
We should defer eventfd_signal() to the workqueue when
eventfd_signal_allowed() return false rather than return
true.
Fixes: b542e383d8c0 ("eventfd: Make signal recursion protection a task bit")
Signed-off-by: Xie Yongji <xieyongji@bytedance.com>
Link:
https://lore.kernel.org/r/20210913111928.98-1-xieyongji@bytedance.com
Reviewed-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/aio.c
patch
|
blob
|
history
diff --git
a/fs/aio.c
b/fs/aio.c
index f7d47c9ff6deb8de81f466cafd6b669c981573f6..1a78979663dca98aee2219e8818bc917e50f3f28 100644
(file)
--- a/
fs/aio.c
+++ b/
fs/aio.c
@@
-1761,7
+1761,7
@@
static int aio_poll_wake(struct wait_queue_entry *wait, unsigned mode, int sync,
list_del_init(&req->wait.entry);
list_del(&iocb->ki_list);
iocb->ki_res.res = mangle_poll(mask);
- if (iocb->ki_eventfd && eventfd_signal_allowed()) {
+ if (iocb->ki_eventfd &&
!
eventfd_signal_allowed()) {
iocb = NULL;
INIT_WORK(&req->work, aio_poll_put_work);
schedule_work(&req->work);