From: Nick Piggin <piggin@cyberone.com.au>

>It does great blobs of IO and then large periods of nothing at all.
>
>
>It's fishy that the scheduler submitted 100MB of I/O in a single second
>against an IDE disk.  That's 800 requests, *assuming* they're all
>maximum-sized, which they are not.
>
>I'd say that your code is allowing nr_requests to be exceeded, by a lot.
>
>

Yes, you're probably right. Does this help?



 drivers/block/ll_rw_blk.c |    3 +++
 1 files changed, 3 insertions(+)

diff -puN drivers/block/ll_rw_blk.c~blk-batching-throttle-fix drivers/block/ll_rw_blk.c
--- 25/drivers/block/ll_rw_blk.c~blk-batching-throttle-fix	2003-06-18 00:17:29.000000000 -0700
+++ 25-akpm/drivers/block/ll_rw_blk.c	2003-06-18 00:17:29.000000000 -0700
@@ -1408,6 +1408,9 @@ static struct request *get_request(reque
 		spin_unlock_irq(q->queue_lock);
 		goto out;
 	}
+
+	if (ioc_batching(ioc))
+		ioc->nr_batch_requests--;
 	
 	INIT_LIST_HEAD(&rq->queuelist);
 

_