On 18 Sep 2000, Peter Osterlund wrote:
> Andrea Arcangeli <firstname.lastname@example.org> writes:
> > > The only disadvantage I can see is that the new patch doesn't handle
> > > consecutive insertions in O(1) time, but then again, the pre-latency
> > We can still do that by trivially fixing a bit your code. You should first
> > check if the new inserted request is over the last in the current queue before
> > entering the tmp1/tmp2 logic.
> Yes this can be done, but it will affect where requests are inserted.
> Suppose the queue currently contains:
> 100 200 300 400 10 20 30
> If request 150 is to be inserted, then with my previous patch it
> will be inserted between 100 and 200, but with the proposed
> change it will instead be inserted at the end.
This is a bug in Andrea's idea. The request should only
be inserted at the end of the list if:
1) the block numbre is bigger than head->prev (which you
2) the block number is smaller than head (or head->next
if the current request is unplugged)
-- "What you're running that piece of shit Gnome?!?!" -- Miguel de Icaza, UKUUG 2000
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to email@example.com Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 21:00:20 EST