aio: Fix incorrect usage of eventfd_signal_allowed()
authorXie Yongji <xieyongji@bytedance.com>
Mon, 13 Sep 2021 11:19:28 +0000 (19:19 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 14 Dec 2021 09:57:22 +0000 (10:57 +0100)
commit4a7c65506473dc1415e6eadcea16e53d12740f6b
treebfb60e9fa7899fc056b38c27c9ea79de2495b82e
parentd99d861ce3ef9b6acbcbbd60406bda2da34df91e
aio: Fix incorrect usage of eventfd_signal_allowed()

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