Skip to content

Commit

Permalink
cfq-iosched: make nonrot check logic consistent
Browse files Browse the repository at this point in the history
cfq_arm_slice_timer() has logic to disable idle window for SSD device. The same
thing should be done at cfq_select_queue() too, otherwise we will still see
idle window. This makes the nonrot check logic consistent in cfq.
Tests in a intel SSD with low_latency knob close, below patch can triple disk
thoughput for muti-thread sequential read.

Signed-off-by: Shaohua Li <shaohua.li@intel.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
  • Loading branch information
Shaohua Li authored and Jens Axboe committed Dec 4, 2009
1 parent 237e5bc commit 3c764b7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion block/cfq-iosched.c
Original file line number Diff line number Diff line change
Expand Up @@ -1796,7 +1796,8 @@ static bool cfq_should_idle(struct cfq_data *cfqd, struct cfq_queue *cfqq)
return false;

/* We do for queues that were marked with idle window flag. */
if (cfq_cfqq_idle_window(cfqq))
if (cfq_cfqq_idle_window(cfqq) &&
!(blk_queue_nonrot(cfqd->queue) && cfqd->hw_tag))
return true;

/*
Expand Down

0 comments on commit 3c764b7

Please sign in to comment.