Jens Axboe
844d2025b6
eventfd: track eventfd_signal() recursion depth
...
commit b5e683d5ca upstream.
eventfd use cases from aio and io_uring can deadlock due to circular
or resursive calling, when eventfd_signal() tries to grab the waitqueue
lock. On top of that, it's also possible to construct notification
chains that are deep enough that we could blow the stack.
Add a percpu counter that tracks the percpu recursion depth, warn if we
exceed it. The counter is also exposed so that users of eventfd_signal()
can do the right thing if it's non-zero in the context where it is
called.
Cc: stable@vger.kernel.org # 4.19+
Signed-off-by: Jens Axboe <axboe@kernel.dk >
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
2020-02-11 04:35:37 -08:00
..
2020-01-14 20:08:28 +01:00
2019-12-17 19:56:49 +01:00
2019-10-29 16:27:17 -07:00
2020-01-26 10:01:07 +01:00
2020-01-29 16:45:33 +01:00
2020-02-01 09:34:51 +00:00
2020-02-01 09:34:49 +00:00
2020-01-23 08:23:00 +01:00
2019-12-31 16:46:06 +01:00
2019-10-30 12:04:35 -04:00
2020-02-01 09:34:32 +00:00
2020-01-09 10:19:59 +01:00
2020-02-11 04:35:11 -08:00
2020-01-09 10:19:54 +01:00
2020-01-23 08:22:32 +01:00
2019-10-31 21:41:33 +01:00
2019-11-29 10:10:08 +01:00
2019-11-04 12:22:02 +01:00
2020-02-11 04:35:25 -08:00
2020-01-04 19:17:24 +01:00
2020-01-04 19:17:00 +01:00
2020-01-09 10:19:58 +01:00
2019-10-22 12:54:44 -07:00
2019-10-31 09:40:19 +01:00
2020-02-11 04:35:37 -08:00
2019-10-18 15:32:52 +02:00
2019-10-22 11:26:09 -07:00
2019-12-17 19:55:30 +01:00
2019-11-29 10:10:13 +01:00
2019-10-28 16:17:31 -07:00
2020-01-04 19:18:41 +01:00
2019-11-08 08:46:49 -08:00
2020-01-12 12:21:46 +01:00
2019-10-24 14:53:49 -07:00
2019-10-24 14:53:48 -07:00
2019-10-24 14:53:49 -07:00
2019-11-11 16:10:54 +01:00
2019-12-31 16:44:14 +01:00
2019-12-13 08:42:53 +01:00
2019-12-13 08:42:53 +01:00
2019-11-12 13:19:15 -08:00
2020-01-09 10:19:59 +01:00
2020-01-04 19:18:28 +01:00
2020-01-09 10:19:56 +01:00
2019-11-15 18:34:00 -08:00
2019-10-17 16:31:52 -07:00
2019-12-13 08:43:18 +01:00
2019-11-06 08:28:58 -08:00
2020-01-23 08:22:40 +01:00
2020-01-23 08:22:39 +01:00
2019-12-31 16:41:16 +01:00
2020-01-29 16:45:21 +01:00
2020-01-09 10:19:41 +01:00
2019-12-31 16:44:40 +01:00
2019-12-31 16:44:43 +01:00
2020-02-11 04:35:28 -08:00
2019-11-06 08:28:58 -08:00
2020-01-09 10:19:53 +01:00
2019-10-28 11:02:01 +01:00
2019-12-31 16:41:26 +01:00
2019-12-21 11:04:31 +01:00
2020-01-04 19:18:48 +01:00
2020-01-04 19:17:25 +01:00
2019-12-17 19:56:43 +01:00
2019-11-01 22:26:34 -04:00
2020-01-04 19:19:13 +01:00
2019-10-28 12:18:23 +01:00
2019-10-24 10:26:33 +02:00
2020-02-05 21:22:43 +00:00
2019-10-31 09:40:21 +01:00
2020-01-04 19:18:39 +01:00
2020-01-23 08:22:45 +01:00
2019-10-31 14:01:40 -07:00
2020-01-04 19:18:42 +01:00
2019-12-18 16:08:43 +01:00
2020-01-23 08:22:44 +01:00
2020-01-17 19:48:40 +01:00
2019-10-28 04:25:04 -04:00