[lkml]   [1998]   [Nov]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: elevator algorithm bug in ll_rw_blk.c
On Fri, 13 Nov 1998, Chris Wedgwood wrote:

> On Mon, Nov 09, 1998 at 11:37:43PM +0000, Stephen C. Tweedie wrote:
> > <> said:
> >
> > > as v2.2 is expected soon I better bring this topic up now. As you
> > > know the "elevator algorihm" is employed for disk I/O, but -- it
> > > *looks* broken to me.
> >
> > It isn't!
> How long has it not been broken for?
> I ask this because back aroun 2.1.26 I made a small char device which
> allowed to to log and then dump the sequences of disk update produced
> during a `sync' operation.
> Anyhow, the net result of this was that they were not optimally
> order, not even close.

Optimal order is not possible unless you know the future ;-)

The request *should* be optimally ordered within the current request queue
state. I.e. if the queue has request for the blocks [4, 10000, 10005] and
the 'elevator' is going 'up', you issue 4, then 10000. If you then get a
new request for block 5, your're out of luck. This is the classical
elevator alg. from OS course, I assume that's what Linux uses.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:45    [from the cache]
©2003-2014 Jasper Spaans. hosted at Digital Ocean