Skip to contentSkip to conversation

large-nand flash mount ?

DISCUSSION 최영일 3 participants 3 messages Sep 27, 2005 – Oct 2, 2005 Memory technology devices (MTD)

lore
Share & tools
lore

최영일

author
#0 lore raw

Hi
I am developing system with cpu au1550 and 2G nand flash?
I want root filesystem by 2G nand flash.
for test, I can mount nand flash and read, write to flash. so, I make jffs2 filesystem and write to flash.
then, I make to boot with boot argument(root=/dev/mtdblock0), but fail the message follows
----------------------------
mtdblock_open
ok
mtdblock: read on "Db1550 NAND FS 0" at 0x400, size 0x200
nand_read_ecc: from = 0x00000400, len = 512
mtdblock: read on "Db1550 NAND FS 0" at 0x600, size 0x200
nand_read_ecc: from = 0x00000600, len = 512 mtdblock_release
nand_sync: called
ok

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(31,0)
-----------------------------------

did anyone success to root mount with 2G large nand flash(jffs2)?

#1 lore raw
Quoted 9 lines · 최영일

Hi
I am developing system with cpu au1550 and 2G nand flash?
I want root filesystem by 2G nand flash.
for test, I can mount nand flash and read, write to flash. so, I make jffs2 filesystem and write to flash.
then, I make to boot with boot argument(root=/dev/mtdblock0), but fail the message follows
----------------------------
mtdblock_open

Quoted 8 lines

ok
mtdblock: read on "Db1550 NAND FS 0" at 0x400, size 0x200
nand_read_ecc: from = 0x00000400, len = 512
mtdblock: read on "Db1550 NAND FS 0" at 0x600, size 0x200
nand_read_ecc: from = 0x00000600, len = 512 mtdblock_release
nand_sync: called
ok

Even if you have healed your problems with MTD, JFFS2 is anyway unusable on large flashes. Hmm, MTD archive seems broken, so I just insert here my recent reply to similar questions.

-------- Original Message --------
Subject: Re: fragtree method?
Date: Mon, 26 Sep 2005 12:16:01 +0400
From: Artem B. Bityutskiy <[email protected]>
To: [email protected] <[email protected]>
CC: Linux MTD <[email protected]>
References: <[email protected]>

Hello Hinko,

Quoted 4 lines · [email protected] wrote:

Hello all,

We are using JFFS2 fs on toshiba NAND flash. There are several partitions defined, but scan time at boot time gets longer every day

of

Quoted 1 line

usage. Eg. when flash is empty it takes ~10 s to mount 20Mb of flash

in

Quoted 1 line

3 partitions later when there are some files present it takes > 30s

and

Quoted 1 line

increasing.

The picture you are observing is normal for JFFS2. The more data is in your flash, the longer is JFFS2 being mounted. I would shortly explain this as follows.

There is no indexing information stored on the flash media. Each JFFS2 node contains full information about itself, but there is no central index. The index is the crucial part of any file system as it is used to
quickly locate any piece of information (i.e., find all the files kept in a directory, find the physical flash address where the files data is stored, etc.). In JFFS2, the index is maintained in RAM and takes significant amount of it. Roughly speaking, there is a in-RAM data structure for each on-flash node.

The in RAM index must be built on each mount. For this reason, JFFS2 must scan the flash media. And it is logically then the more data you have on flash, the longer is JFFS2 mount time and memory consumption. Namely, the above 2 characteristics linearly depend on the flash size (O(N), N - flash size).

You may also glance at
http://www.linux-mtd.infradead.org/tech/JFFS3design.pdf for some additional info.

Signature · 3 lines
Best Regards,
Artem B. Bityuckiy,
St.-Petersburg, Russia.
#2 lore raw
Quoted 19 lines · Artem B. Bityutskiy
Quoted 9 lines · 최영일

Hi
I am developing system with cpu au1550 and 2G nand flash?
I want root filesystem by 2G nand flash.
for test, I can mount nand flash and read, write to flash. so, I make jffs2 filesystem and write to flash.
then, I make to boot with boot argument(root=/dev/mtdblock0), but fail the message follows
----------------------------
mtdblock_open

Quoted 8 lines

ok
mtdblock: read on "Db1550 NAND FS 0" at 0x400, size 0x200
nand_read_ecc: from = 0x00000400, len = 512
mtdblock: read on "Db1550 NAND FS 0" at 0x600, size 0x200
nand_read_ecc: from = 0x00000600, len = 512 mtdblock_release
nand_sync: called
ok

Quoted 3 lines

Even if you have healed your problems with MTD, JFFS2 is anyway unusable on large flashes. Hmm, MTD archive seems broken, so I just insert here my recent reply to similar questions.

You might want to try looking at YAFFS.

YAFFS has been used successfully with quite large NAND arrays (at least as large as 1.5G bytes). 2GB should be very achievable.

-- Charles