Commit 256e7fe0 authored by Jens Axboe's avatar Jens Axboe Committed by Linus Torvalds

[PATCH] cfq-iosched: fix scsi requeue accounting

The accounting can go bad in the requeue hook, it must check the
accounted flag to make sure it was previously considered in the driver.
Signed-off-by: default avatarJens Axboe <axboe@suse.de>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 867761b6
...@@ -622,9 +622,11 @@ static void cfq_requeue_request(request_queue_t *q, struct request *rq) ...@@ -622,9 +622,11 @@ static void cfq_requeue_request(request_queue_t *q, struct request *rq)
cfq_sort_rr_list(cfqq, 0); cfq_sort_rr_list(cfqq, 0);
} }
if (crq->accounted) {
crq->accounted = 0; crq->accounted = 0;
cfqq->cfqd->rq_in_driver--; cfqq->cfqd->rq_in_driver--;
} }
}
list_add(&rq->queuelist, &q->queue_head); list_add(&rq->queuelist, &q->queue_head);
} }
......
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