Re: 2.5.1-pre3 FIXED (was Re: 2.5.1-pre3 DON'T USE)

Jens Axboe (axboe@suse.de)
Fri, 30 Nov 2001 09:59:20 +0100


On Fri, Nov 30 2001, andersg@0x63.nu wrote:
> On Thu, Nov 29, 2001 at 12:14:31PM +0100, Jens Axboe wrote:
> > On Thu, Nov 29 2001, Jens Axboe wrote:
> > > Hi,
> > >
> > > Please don't use this kernel unless you can afford to loose your data.
> > > I'm looking at the problem right now.
> >
> > Ok the problem was only on highmem machines, the copying of data was
> > just wrong. The attached patch fixes that and a few other buglets, such
> > as:
> >
> > - BIO_HASH remnant in LVM
>
> shouldn't line 1046 in lvm.c be:
> bio.bi_io_vec[0].bv_len = lvm_get_blksize(bio.bi_dev);
>
> with this patch it atleast compiles..
>
> --- linux-2.5.1-pre4-vanilj/drivers/md/lvm.c Fri Nov 30 09:45:31 2001
> +++ linux-2.5.1-pre4/drivers/md/lvm.c Fri Nov 30 09:32:42 2001
> @@ -1043,7 +1043,7 @@
>
> memset(&bio,0,sizeof(bio));
> bio.bi_dev = inode->i_rdev;
> - bio.bi_io_vec.bv_len = lvm_get_blksize(bio.bi_dev);
> + bio.bi_io_vec[0].bv_len = lvm_get_blksize(bio.bi_dev);
> bio.bi_sector = block * bio_sectors(&bio);
> bio.bi_rw = READ;
> if ((err=lvm_map(&bio)) < 0) {

memset(bio...) and then deref bi_io_vec, not a good idea. Then leaving
it in a non-compileable state for now is preferable.

-- 
Jens Axboe

- 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/