From: Jens Axboe Date: Sat, 3 Oct 2009 17:46:03 +0000 (+0200) Subject: cfq-iosched: use assigned slice sync value, not default X-Git-Tag: 2.1b_release~10711^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=61f0c1dcaaac71faabac6ef7c839b29f20204bea;p=platform%2Fkernel%2Fkernel-mfld-blackbay.git cfq-iosched: use assigned slice sync value, not default We should use the sysfs modified slice sync value, in case it differs from the default. Signed-off-by: Jens Axboe --- diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index 3010e2e..ebab60c 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -1348,12 +1348,13 @@ static int cfq_dispatch_requests(struct request_queue *q, int force) /* * must wait a bit longer */ - if (last_sync < cfq_slice_sync) { - cfq_schedule_dispatch(cfqd, cfq_slice_sync - last_sync); + if (last_sync < cfqd->cfq_slice[1]) { + cfq_schedule_dispatch(cfqd, + cfqd->cfq_slice[1] - last_sync); return 0; } - depth = last_sync / cfq_slice_sync; + depth = last_sync / cfqd->cfq_slice[1]; if (depth < max_dispatch) max_dispatch = depth; }