root=/dev/mtdblock doesn't work with kernel 2.4.18
Hi!
After changing from 2.4.8-pre4 to a 2.4.18 kernel I can't mount the flash as root device any more. I'm using the "root=" boot argument to do so. The filesystem (cramfs) is alredy detected in mount_root() (super.c) when mount_root calls blkdev_put(bdev, BDEV_FS); Which for some reasons has to call the release function of the device which results in mtdblock_release() being called. The hole thing stops when invalidate_device() calls fsync_dev(dev). Where we'll shurely get back to the MTD driver (some how). Calling blk_dev_get() and blk_dev_put() in mount_root() is a difference between both kernel versions. But removing that change simply leades to another problem...
Everything works fine when running with NFS as rootfs mounting the flash with /etc/fstab. So it looks like this is some kind of race condition.
Maybe this is an issue to the FS people. But you should have experience with using the rootfs that way.
Thanks, Stephan
#--
STEPHAN LINKE (dipl. inform); software engineer
epygi labs de gmbh; herrenstraße 23, 3. og, D-76133 karlsruhe http://www.epygi.de; mailto:[email protected] phone 0721-20596-30; fax 0721-20596-59
----------------------------------------
Motto: „Wenn es defekt ist, dann isses kaputt!“
Quoted 7 lines · Stephan Linke
After changing from 2.4.8-pre4 to a 2.4.18 kernel I can't mount the flash as root device any more. I'm using the "root=" boot argument to do so. The filesystem (cramfs) is alredy detected in
mount_root()(super.c) whenmount_rootcallsblkdev_put(bdev, BDEV_FS); Which for some reasons has to call the release function of the device which results inmtdblock_release()being called. The hole thing stops wheninvalidate_device()callsfsync_dev(dev).
Remove just the call to invalidate_device() in mtdblock_release()
Signature · 1 line
dwmw2
Thank's David! Now it works.
Quoted 2 lines
Quoted 2 lines
After changing from 2.4.8-pre4 to a 2.4.18 kernel I can't mount the
flash as
Quoted 2 lines
Quoted 2 lines
root device any more. I'm using the "root=" boot argument to do so. The filesystem (cramfs) is alredy detected in
mount_root()(super.c)
when
Quoted 1 line
Quoted 1 line
mount_rootcallsblkdev_put(bdev, BDEV_FS); Which for some reasons has
to
Quoted 1 line
Quoted 1 line
call the release function of the device which results in
mtdblock_release()
Quoted 8 lines
Quoted 2 lines
being called. The hole thing stops when
invalidate_device()callsfsync_dev(dev).Remove just the call to
invalidate_device()inmtdblock_release()--
dwmw2