Re: plugging in 2.4. Does it work?

Peter T. Breuer (ptb@it.uc3m.es)
Wed, 21 Feb 2001 00:48:22 +0100 (MET)


"A month of sundays ago Jens Axboe wrote:"
> On Wed, Feb 21 2001, Peter T. Breuer wrote:
> > Hurrr ... are you saying that the buffers in the bh's in the request are
> > not contiguous? My reading of the make_request code in 2.2 was that
> > they were! Has that changed? There is now a reference to an elevator
> > algorithm in the code, and I can't make out the effect by looking ...
> > I have been copying the buffer in the request as though it were a single
> > contigous whole. If that is not the case, then yes, bang would happen.
>
> Nothing has changed in this regard at all between 2.2 and 2.4. The
> buffers are guaranteed to be sequentially sector-wise, but definitely
> not contigious in memory!

I recall that in 2.2 the make_request code tested that the
buffers were contiguous in memory. From 2.2.18:

/* Can we add it to the end of this request? */
if (back) {
if (req->bhtail->b_data + req->bhtail->b_size
!= bh->b_data) {
if (req->nr_segments < max_segments)
req->nr_segments++;
else break;
}

It looks to me like it tested that the b_data char* pointers of the
two requests being considered are exactly distant by the declared
size of one.

Is that no longer the case? If so, that's my answer.

Peter
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/