Re: report bug: System reboots when accessing a loop-device over a second loop-device with 2.4.2-ac7

From: Jens Axboe (axboe@suse.de)
Date: Thu Mar 01 2001 - 11:21:45 EST


On Thu, Mar 01 2001, Mario Hermann wrote:
> I tried the following commands with 2.4.2-ac7:
>
> losetup /dev/loop0 test.dat
> losetup /dev/loop1 /dev/loop0
> mke2fs /dev/loop1
>
> My System reboots immediatly. I tried it with 2.4.2-ac4,ac5 too -> same
> effect.
>
> With 2.4.2 it hangs immediatly.

This should make it work again.

-- 
Jens Axboe

--- /opt/kernel/linux-2.4.2-ac7/drivers/block/loop.c Thu Mar 1 15:46:14 2001 +++ drivers/block/loop.c Thu Mar 1 17:17:13 2001 @@ -397,10 +397,10 @@ if (!buffer_locked(rbh)) BUG(); - if (MINOR(rbh->b_dev) >= max_loop) + if (MINOR(rbh->b_rdev) >= max_loop) goto out; - lo = &loop_dev[MINOR(rbh->b_dev)]; + lo = &loop_dev[MINOR(rbh->b_rdev)]; spin_lock_irq(&lo->lo_lock); if (lo->lo_state != Lo_bound) goto inactive;

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



This archive was generated by hypermail 2b29 : Wed Mar 07 2001 - 21:00:09 EST