[Yaffs-archive] Re: corrupt my NAND flash device

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Charles Manning
Date:  
To: Paul Wong, yaffs list
Subject: [Yaffs-archive] Re: corrupt my NAND flash device
On Tuesday 22 April 2003 19:51, Paul Wong wrote:
>  Hi all!
>      i installed the YAFFS file system in the NAND flash (samsung 16MB).
> And test the reliability. I tried to copy a 5 MB file to the mounted yaffs
> (spare 8MB) directory ( i separated the device to 3 partition - 4MB 4MB and
>   8MB) . and then check the disk space, it is shown that it has 3 MB spare.
>   Next step, I erased the file and copied another 5 MB file to it. The
> device
>   said " no enough spare. Then I use the "mkyaffs" to format it, it is
> shown many bad block in the device. I checked the OOB[5] ( bad block flag)
> it is set to 0x00. Why? Why the yaffs set the health block to the bad block
> after
>   erase file? Is the YAFFS not support big file ?  any ideal?



Can you send the output of /proc/yaffs?

YAFFS certianly supports large files and you should not be seeing problems
like these.

As YAFFS writes data to the NAND it checks the results. If it encounters data
errors then it marks the block for retirement and you get ""**>>Block %d
marked for retirement" messages. Later on, during garbage collection, these
blocks will be marked as bad blocks.

I suggest that while you figure the problem out you first disable the bad
block marking. You can do this by commenting out the two lines in
yaffs_RetireBlock() that write to NAND. Now the software will think these
blocks have been retired, but the NAND will not be marked.

I have seen this problem before where the NAND read/write algorithms were not
working properly and YAFFS was thus seeing bad data and thought the blocks
were bad.

You might, of course, really have a bad chip or bad soldering etc. You should
not have more than approx 1-2% bad blocks.

-- 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 with the text "unsubscribe"
(without the quotes) as the subject.