[Yaffs] yaffs1/2 autodetect idea

Charles Manning manningc2 at actrix.gen.nz
Tue Nov 1 21:21:09 GMT 2005


On Friday 28 October 2005 21:31, Nick Bane wrote:

> Supplementally:
> One can specify rootfs in the kernel build as a default command line but
> this presupposes that one knows what the nand type will be. For systems
> with mixed nand builds (we have 32MB boards using 512b to 384MB using 3
> 1GBit 2k) a single kernel is often desireable for production. In our
> version of bootldr (see
> http://husaberg.toby-churchill.com/balloon/releases/development/bootldr/boo
>tldr36) 2k/512 byte pages size for the root mtd device is detected and
> rootfs=yaffs/yaffs2 is selected. In addition, due to the number of
> overhead blocks, our first small boot partition is dynamically sized to
> make sure there is enough free space for a kernel.
>
> BTW, using rootfs= is also the recommended way of booting a jffs2 root
> fs acording to the Handhelds folks.

Nick

There are probably quite a few people with the requirement of one firmware 
supporting both 512 and 2k NAND board variants.

Would it help to modify yaffs2 to automatically handle the yaffs1 case? ie 
something along the lines of:

  sniff mtd
  if mtd page size == 512 then  yaffs1 handling
  else  yaffs2 handling

That should be pretty straight forward to do and would save having to do the 
decision making elsewhere.

Thoughts?

-- CHarles



More information about the yaffs mailing list