[Yaffs] Re: Yaffs direct

Charles Manning manningc2 at actrix.gen.nz
Fri Apr 21 05:05:54 BST 2006


On Friday 21 April 2006 10:48, Sean Kelley wrote:
> For FAT compatibility, i.e., USB mass storage, you could always just
> have a FAT file image that just lives on the YAFFS filesystem.

Well... 

You'd have to implement a mass storage device (== block driver) on top of 
YAFFS, and then FAT on top of the block driver. 

These would no longer be YAFFS files, but would be FAT files. You'd be 
throwing away all the YAFFS robustness due to log structure etc.

If you must do FAT then it is probably simpler & more efficient to  just do  a 
FAT file system on top of a block driver and leave YAFFS out of the picture.

>
> Sean
>
> On 4/20/06, Wookey <wookey at aleph1.co.uk> wrote:
> > +++ Ian Oliver [06-04-20 10:08 +0100]:
> > > In article <200604200805.41158.manningc2 at actrix.gen.nz>, Charles
> > > Manning wrote:
> > >
> > > Is this summary correct -
> > > Not only doesn't Linux yaffs need MTD, but it can't us it?
> >
> > Yaffs doesn't need MTD, but it can use it if you like (and most people do
> > under linux).

YAFFS can and does work with the mtd with some twists. YAFFS1 (512-byte pages) 
is a straight drop in. With yaffs2 there are some incompatabilities that are 
fully ironed out. Some people can get a solution working with "Sergey's 
patch" - found on the list, but this does not always work. 

Most people who're chasing performance toss out the standard mtd driver code 
and just write there own. I'm not throwing rocks at mtd, it is just that 
taylored code is always going to be faster than generic code.


> >
> > > But yaffs direct provides chunk management so we can sit our own
> > > fat/fat32 on top of it? (with some interface wrangling to map the block
> > > requests to the yaffs chunk management - we need fat32 for the
> > > non-Linux case)
> >
> > I think that's possible, yes, but Charles is best-placed to comment on
> > the efficiency and how much work is involved. It is something a few
> > people have mentioned (as fat-comptibility is obviously generally-useful)
> > but I'm not aware of anyone having actually implemented it.
> >

As per near the top, the actual compatability would be limited because you'd 
lose the yaffs file integrity features.

Unfortunately, USB Mass Storage == a block driver. If it was a file-based 
interface (like nfs), then you'd be able to run yaffs on the target.

-- Charles






More information about the yaffs mailing list