UBIFS fails to mount on second boot

Artem Bityutskiy dedekind1 at gmail.com
Wed Jun 27 10:10:19 EDT 2012


Hi,

On Mon, 2012-06-25 at 15:23 +1000, Iwo wrote:
> I'm trying to use a UBIFS partition as the linux root filesystem.
> After flashing the
> UBI image, the system boots successfully and is functional.
> 
> On the second boot, however, mounting of the UBIFS fails and the kernel panics.

So this is reproducible? Can you provide me the ubifs image?

> It is possible to avoid the failure by performing a large number of filesystem
> operations (i.e. file system benchmark) during the first session.

Hmm, sounds strange.

> Has anyone seen this before? Suggestions?

Similar issue was reported once and the reported disappeared:
http://lists.infradead.org/pipermail/linux-mtd/2012-June/042046.html

> The hardware is a TI am335x processor with a 256MB, 2K pages, 128K erase block
> NAND flash.

SLC flash?

Did you validate your flash with MTD tests?

> As is all too common, the flash supports sub-pages, the driver does
> not. Thus, I'm
> forcing the VID header offset to 2048.

This means the driver is buggy: it does not support sub-pages but still
reports that it does. Just fix it instead.

> The kernel is a 3.1.0 with TI patches and UBI+UBIFS patches from
> git://git.infradead.org/~dedekind/ubifs-v3.1.git today. I had to change
> IS_ENABLED(DEBUG_FS) to IS_ENABLED(CONFIG_DEBUG_FS)
> to make that compile. The original v3.1.0 UBI/UBIFS code exhibited
> the same behaviour though.

I'll fix the IS_ENABLED stuff, sorry for that.

> The image is generated like so (using the latest MTD tools GIT):
> 
>  mkfs.ubifs -d staging -F -o root.ubifs -m 0x800 -e 126976 -c 511

Did you try to mount an empty volume and let UBIFS auto-format it, and
then reproduce the issue?

-- 
Best Regards,
Artem Bityutskiy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <http://lists.infradead.org/pipermail/linux-mtd/attachments/20120627/e4cc81bc/attachment.sig>


More information about the linux-mtd mailing list