[Yaffs] Need help replacing yaffs1 by yaffs2

Jacob Dall jacob.dall@operamail.com
Sat, 11 Dec 2004 00:24:14 +0100


Please, I need some help.

I want to replace yaffs1 direct with yaffs2 direct, but I've some trouble.

I've compiled the code with the CFLAGS as defined in the direct/makefile: C=
ONFIG_YAFFS_DIRECT, CONFIG_YAFFS_SHORT_NAMES_IN_RAM and CONFIG_YAFFS_YAFFS2=
. I'm a bit in doubt about the last define - is it ok setting it when one w=
ants to do what I want?

I've completed a low-lewel check of the flash, using my implementation of t=
he interface functions in direct/yaffs_flashif.c. The test is done by writi=
ng some well-known values to the data and spare area of each chunk, reading=
 it back and verifying byte by byte. I do not allow any diffs. It runs to p=
erfection - I get no errors at all.=20

Now, starting up yaffs (of course I did erase all blocks after the low-leve=
l check was completed), mounting a device and opening, writing and closing =
some files, for each file I get some 'ecc error unfixed' notes, and a block=
 is marked for retirement. I don't get that, taking into consideration that=
 my previous test showed no issues at all.

Digging into the code, I can't seem to locate the spot where data ecc is ca=
lculated (beyond some code not being active, either by #ifdef 0 or //).

I tend to believe that what I want to achieve is either unsupported or unte=
sted. Am I right?

Still, I don't get it - where is the data ecc supposed to be calculated?

Thanks,
Jacob Dall