Re: [Yaffs] Problem with Yaffs on Routerboard RB112 and kern…

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: David Goodenough
Date:  
To: yaffs
Subject: Re: [Yaffs] Problem with Yaffs on Routerboard RB112 and kernel 2.6.19
On Wednesday 09 May 2007, Charles Manning wrote:
> If you're getting ECC errors here it is possibly because the flash has been
> written using yaffs_ecc.c and read (with nand_dump) using mtd's nand_ecc.c
>
> nand_ecc.c generates exaclty the same data as yaffs_ecc.c, but the byte
> ordering is different. Both implement the SmartMedia ECC mechanism, but the
> byte order is broken in nand_ecc.c

Reading this I thought that I would look at the config options for MTD. And
sure enough there is one (that was not set) called CONFIG_MTD_NAND_ECC_SMC
which was not set. So I tried setting it, but it does not seem to make any
difference - I get the same problems.

When I mount the partition, all the blocks are flaged as bad and when I use
nanddump it complains about uncorrectable bitflips just as before.

What change is needed to nand_ecc.c to get the byte order the same as
yaffs_ecc.c. A brief look had them looking very similar, but of course I
may have missed something.

David
>
> There are two solutions to this mess:
> 1) Microtik should provide their driver configs under GPL.
> 2) Trace through the data reading/writing to see where the OOB byte
> ordering is getting screwed up.
>