Commit 97d26ae7 authored by Li Lei's avatar Li Lei Committed by Jens Axboe

bcache: remove unnecessary flush_workqueue

All pending works will be drained by destroy_workqueue(), no need to call
flush_workqueue() explicitly.
Signed-off-by: default avatarLi Lei <lilei@szsandstone.com>
Signed-off-by: default avatarColy Li <colyli@suse.de>
Link: https://lore.kernel.org/r/20220919161647.81238-2-colyli@suse.deSigned-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 91418cc4
......@@ -801,10 +801,9 @@ static int bch_writeback_thread(void *arg)
}
}
if (dc->writeback_write_wq) {
flush_workqueue(dc->writeback_write_wq);
if (dc->writeback_write_wq)
destroy_workqueue(dc->writeback_write_wq);
}
cached_dev_put(dc);
wait_for_kthread_stop();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment