question > new jffs2 partition

Ricard Wanderlof ricard.wanderlof at axis.com
Wed Mar 19 06:01:03 EDT 2008


On Wed, 19 Mar 2008, gxk wrote:

> Does the kernel format erased flash, defined as partition?
>
> From the Uboot prompt i erase the space:
> erase 0xa0000000 +2800000
>
> Configured my kernel to have 3 partitions.
> The 3rd is started at address 0xa0000000 with size 0x2800000.
> This partition mounted at system boot:
>
> mount -t jffs22 /dev/mtdblock/2 /mnt
>
> and after simple make dir
>
> mkdir -p /mnt/abcd
>
> Now, when i start the system 1st time, it is taking more time to load
> at the `mkdir'. All follow reboots go smooth.
>
> It is look like mtd driver formats the partition. Can anybody confirm this?
> When is it happen?

mtd doesn't, but the jffs2 driver erases all seemingly empty blocks and 
writes cleanmarkers to them. This is ultimately handled by the pdflush 
kernel task once the kernel is up and running, and for some reason it 
takes quite a while to accomplish, e.g. pdflush runs with a high CPU load 
for a minute or so although the required operations would take just a few 
seconds. I once tried to dive into the code to figure out why but failed 
to come up with anything.

/Ricard
--
Ricard Wolf Wanderlöf                           ricardw(at)axis.com
Axis Communications AB, Lund, Sweden            www.axis.com
Phone +46 46 272 2016                           Fax +46 46 13 61 30



More information about the linux-mtd mailing list