diff options
author | Jens Axboe <axboe@kernel.dk> | 2021-09-01 11:18:41 -0600 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-09-01 12:35:32 -0600 |
commit | 15e20db2e0cecce0bfc6a67b69e55020fe9cda00 (patch) | |
tree | 74de1572a73f8dd3630822fa4e89ea41888ec8d2 /fs/io-wq.c | |
parent | f95dc207b93da9c88ddbb7741ec3730c6657b88e (diff) | |
download | linux-15e20db2e0cecce0bfc6a67b69e55020fe9cda00.tar.bz2 |
io-wq: only exit on fatal signals
If the application uses io_uring and also relies heavily on signals
for communication, that can cause io-wq workers to spuriously exit
just because the parent has a signal pending. Just ignore signals
unless they are fatal.
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'fs/io-wq.c')
-rw-r--r-- | fs/io-wq.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/io-wq.c b/fs/io-wq.c index 8cba77a937a1..027eb4e13e3b 100644 --- a/fs/io-wq.c +++ b/fs/io-wq.c @@ -575,7 +575,9 @@ loop: if (!get_signal(&ksig)) continue; - break; + if (fatal_signal_pending(current)) + break; + continue; } if (ret) continue; |