I believe it is correct. Assuming that the list is initially in a
sane state, req->biotail->bi_next will be NULL immediately before
executing the statement that I added. Therefore, my fix will set
bio->bi_next to NULL, which is what we want because bio becomes the
new end of the list.
> > req->biotail = bio;
> > req->nr_sectors = req->hard_nr_sectors +=
> > nr_sectors; @@ -1811,6 +1812,7 @@
> > req->buffer = bio_data(bio); /* see ->buffer comment above */
> > req->waiting = NULL;
> > req->bio = req->biotail = bio;
> > + bio->bi_next = NULL;
>
> No need for that, look at bio_init() in fs/bio.c.
Yes, it looks like bio_init has been added in the 2.5 kernels, solving
the problem. However, this is still a bug in 2.4.20.
-Dave
-
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/