diff options
author | Vivek Goyal <vgoyal@redhat.com> | 2009-12-03 12:59:56 -0500 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-12-03 13:28:53 -0500 |
commit | c04645e592d4dd60c58def40c913699d4c806727 (patch) | |
tree | 61e2b6fac3c9dd0f211c07f024fe5cb17ff5d3cf /block | |
parent | ae30c286553c91c49af5cbc0265a05a6543d0c52 (diff) |
blkio: Wait on sync-noidle queue even if rq_noidle = 1
o rq_noidle() is supposed to tell cfq that do not expect a request after this
one, hence don't idle. But this does not seem to work very well. For example
for direct random readers, rq_noidle = 1 but there is next request coming
after this. Not idling, leads to a group not getting its share even if
group_isolation=1.
o The right solution for this issue is to scan the higher layers and set
right flag (WRITE_SYNC or WRITE_ODIRECT). For the time being, this single
line fix helps. This should not have any significant impact when we are
not using cgroups. I will later figure out IO paths in higher layer and
fix it.
Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/cfq-iosched.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index 063dcbb714e7..08b057b1b3b2 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c | |||
@@ -3314,7 +3314,8 @@ static void cfq_completed_request(struct request_queue *q, struct request *rq) | |||
3314 | * only if we processed at least one !rq_noidle request | 3314 | * only if we processed at least one !rq_noidle request |
3315 | */ | 3315 | */ |
3316 | if (cfqd->serving_type == SYNC_WORKLOAD | 3316 | if (cfqd->serving_type == SYNC_WORKLOAD |
3317 | || cfqd->noidle_tree_requires_idle) | 3317 | || cfqd->noidle_tree_requires_idle |
3318 | || cfqq->cfqg->nr_cfqq == 1) | ||
3318 | cfq_arm_slice_timer(cfqd); | 3319 | cfq_arm_slice_timer(cfqd); |
3319 | } | 3320 | } |
3320 | } | 3321 | } |