]> Git Repo - linux.git/commit - fs/io-wq.c
io-wq: ensure all pending work is canceled on exit
authorJens Axboe <[email protected]>
Wed, 3 Mar 2021 22:47:04 +0000 (15:47 -0700)
committerJens Axboe <[email protected]>
Thu, 4 Mar 2021 13:38:10 +0000 (06:38 -0700)
commitf01272541d2cd7b7f24909d63ea2b028a6a66293
tree94b31ecf630b34f0bb9c686aced0dabedaac470a
parente4b4a13f494120c475580927864cc1dd96f595d1
io-wq: ensure all pending work is canceled on exit

If we race on shutting down the io-wq, then we should ensure that any
work that was queued after workers shutdown is canceled. Harden the
add work check a bit too, checking for IO_WQ_BIT_EXIT and cancel if
it's set.

Add a WARN_ON() for having any work before we kill the io-wq context.

Reported-by: [email protected]
Signed-off-by: Jens Axboe <[email protected]>
fs/io-wq.c
This page took 0.054634 seconds and 4 git commands to generate.