Some observations and hunches.... > So I'm curious to see what performance others are getting (can you also > include your proc and bus speeds?). The WinCE stuff I have played with uses the following hw: * SA1110 @ 206MHz * SDRAM: 100MHz bus * 128MB NAND (2x64MB Samsung parts). Write cycle ~90ns, read ~115ns. Write performance all the way through YAFFS is around 1MB/s. Under Linux I'd expect approx the same performance with a custom NAND access layer (ie. not going through mtd). This is not optimised that much (eg. loops to write data). OK, now the observations: * ECC: ECC speed is largely affected by raw CPU/RAM speed and the algorithm used. nand_ecc.c uses table look-ups and is pretty fast. Slower CPUs will obviously be slower. devices using DRAM instead of SDRAM will probably also get punished on RAM bandwdth. * We're pushing a lot of data. The copy time is critical. NAND can handle 50ns cycles, see how close you can get. * Unwinding loops will give speed. ie. instead of for(i = 0; i < 512; i++) *nand = *buf++; try *nand = *buf++; *nand = *buf++; *nand = *buf++; *nand = *buf++; *nand = *buf++; *nand = *buf++; ... 512 times. This isn't what they taught us in computer science but it should go approx 4x the speed since there are no looping overheads. [The WinCE code could benefit from this too]. * The mtd nand.c buffers the writes internally (JFFS2 friendly). Bypassing the buffering would be faster for YAFFS. * Schedules etc within the mtd layer will yield and probably slow things down. * The erasure model used in mtd could probably be a lot simpler/faster for NAND. Much of the complexity, IMHO, is there to try support both NOR (very slow erase) and NAND through one interface. * Don't do any ECC or verification in the mtd layer since YAFFS does this already. As I don't actually have any nand hw running Linux (and my time is better spent in yaffs_guts) I would appreciate someone else having a play. Keeping the current mtd char device interface is useful for formatting, dumping etc. Yous might find my nandemul code to be a good kickoff point since this has been stripped back pretty hard already. -- Charles --------------------------------------------------------------------------------------- This mailing list is hosted by Toby Churchill open software (www.toby-churchill.org). If mailing list membership is no longer wanted you can remove yourself from the list by sending an email to yaffs-request@toby-churchill.org with the text "unsubscribe" (without the quotes) as the subject.