u-boot is not tolerant of unclean ext2 file systems

Bug #450906 reported by Michael Casadevall on 2009-10-14
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

u-boot will fail to load files from an unclean filesystem. As an ext2 filesystem can be marked unclean just by a sudden restart, this means that the system will then fail to load the uImage and uInitrd from the filesystem. As power interruptions, or a sudden restart is always possible, this creates a situation where the system then must be rescued with an external boot media.

1. Crash the system in a way that causes an ext2 partition to be unclean. (mounting a partition, then suddenly hitting the reset switch should work)
2. Try to load a file at the u-boot prompt, and watch how it fails with an error

1. u-boot attempt to load despite the clean/non-clean status of the filesystem

Loïc Minier (lool) on 2009-10-14
Changed in adana:
importance: Undecided → High

It seems this doesn't always happen when the filesystem is marked unclean, as I just had my Y1 come up properly on an unclean file system, but there were no issues with the directory tree. Obviously the lack of robustness with ext2 is still an issue.

Maen Suleiman (maen-marvell) wrote :

The U-Boot ext2 code actually does test the status field in the superblock structure and thus the U-Boot doesn't care if the ext2 is clean or not.

Maen Suleiman (maen-marvell) wrote :

correction: The U-Boot ext2 code actually does NOT test the status field in the superblock structure and thus the U-Boot doesn't care if the ext2 is clean or not.

Loïc Minier (lool) wrote :

Incomplete for now; please reopen when you have a more specific issue.

Changed in adana:
status: New → Incomplete
Maen Suleiman (maen-marvell) wrote :

As Loic noticed, To work with current U-Boot, EXT2 should be formatted using "mkfs.ext2 -I 128" to limit node size to 128.
It is recommended to format the ext2 file system with "-I 128" to work properly with U-Boot.
Latest mainline U-Boot include a patch that fixes inode calculation and should support inodes with larger size; we are considering applying this patch to our U-Boot.


Michael - Can you please apply this patch and see if it fixes your issue, meanwhile I am having issues with installing ubuntu and can't re-produce it.

Loïc Minier (lool) on 2009-10-15
visibility: private → public
Loïc Minier (lool) wrote :

NB: I made this bug public to document the rationale for the fix to partman-uboot I just uploaded.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers