[ECOS] JFFS2, for Redboot only?

Andrew Lunn andrew@lunn.ch
Tue Mar 2 08:09:00 GMT 2004


On Tue, Mar 02, 2004 at 12:12:14AM -0500, Dirk Broer wrote:
> Looking through the ECOS code and looking through the archives?
> 
> It seems to use JFFS2 I must load up an initial JFFS2 via redboot?
> 
> If the flash is already clear can?t JFFS2 simply use it?

No you need to format the disk before you can write to it. eCos does
not have a native equivalent of mkfs.jffs2 so you need to make a file
system on a host and then transfer it somehow into the flash. 

> Most importantly.  A quick test of JFFS2 and it seems that during
> write the flash is never unlocked.  I did a grep for flash_unlock
> and it only showed up in fis_unlock.  AFAIK, that is a Redboot
> interface.

A Filesystem are going to be making lots of writes to a flash. Do you
really want the overhead of unlocking and locking the flash every
time? It is better to unlock it once when you put in your empty
filesystem and leave it unlocked.

I suppose another way to look at it is, a locked flash is a read-only
filesystem. So jffs2 is probably doing the write thing by refusing to
write to it.

> Does this mean JFFS2 expects an unlocked flash and the unlocking typically
> comes from Redboot?
> 
> Am I missing something?   A resource on the net?

You can also unlock the flash blocks from your own program. It simple
to do.

   Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list