Skip to content

Commit

Permalink
cfq_exit_queue() should cancel cfq_data->unplug_work
Browse files Browse the repository at this point in the history
Spotted by Nick <gentuu@gmail.com>, perhaps explains the first trace in
http://bugzilla.kernel.org/show_bug.cgi?id=9180.

cfq_exit_queue() should cancel cfqd->unplug_work before freeing cfqd.
blk_sync_queue() seems unneeded, removed.

Q: why cfq_exit_queue() calls cfq_shutdown_timer_wq() twice?

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
  • Loading branch information
Oleg Nesterov authored and Jens Axboe committed Oct 29, 2007
1 parent b238b3d commit 4310864
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion block/cfq-iosched.c
Original file line number Diff line number Diff line change
Expand Up @@ -2053,7 +2053,7 @@ static void cfq_shutdown_timer_wq(struct cfq_data *cfqd)
{
del_timer_sync(&cfqd->idle_slice_timer);
del_timer_sync(&cfqd->idle_class_timer);
blk_sync_queue(cfqd->queue);
kblockd_flush_work(&cfqd->unplug_work);
}

static void cfq_put_async_queues(struct cfq_data *cfqd)
Expand Down

0 comments on commit 4310864

Please sign in to comment.