Commit 0b3e8d29 authored by Jens Axboe's avatar Jens Axboe Committed by Linus Torvalds

[PATCH] queue congestion threshold hysteresis

We need to open the gap between congestion on/off a little bit, or we
risk burning many cycles continually putting processes on a wait queue
only to wake them up again immediately. This was observed with CFQ at
least, which showed way excessive sys time.

Patch is from Arjan.
Signed-off-by: default avatarJens Axboe <axboe@suse.de>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 77c22ede
......@@ -100,7 +100,7 @@ static void blk_queue_congestion_threshold(struct request_queue *q)
nr = q->nr_requests;
q->nr_congestion_on = nr;
nr = q->nr_requests - (q->nr_requests / 8) - 1;
nr = q->nr_requests - (q->nr_requests / 8) - (q->nr_requests / 16) - 1;
if (nr < 1)
nr = 1;
q->nr_congestion_off = nr;
......
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