Commit 0b22ff53 authored by Mike Snitzer's avatar Mike Snitzer

dm: remove flush_scheduled_work() during local_exit()

Commit acfe0ad7 ("dm: allocate a special workqueue for deferred
device removal") switched from using system workqueue to a single
workqueue local to DM.  But it didn't eliminate the call to
flush_scheduled_work() that was introduced purely for the benefit of
deferred device removal with commit 2c140a24 ("dm: allow remove to
be deferred").

Since DM core uses its own workqueue (and queue_work) there is no need
to call flush_scheduled_work() from local_exit().  local_exit()'s
destroy_workqueue(deferred_remove_workqueue) handles flushing work
started with queue_work().

Fixes: acfe0ad7 ("dm: allocate a special workqueue for deferred device removal")
Signed-off-by: default avatarMike Snitzer <snitzer@kernel.org>
parent f0ac1598
......@@ -233,7 +233,6 @@ static int __init local_init(void)
static void local_exit(void)
{
flush_scheduled_work();
destroy_workqueue(deferred_remove_workqueue);
unregister_blkdev(_major, _name);
......
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