[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NAND flash and JFFS(2)




Hi Thomas,
I have two questions regarding the layout scheme in oob.

1. What does "page data valid flag" mean ?  How do you use it ?
2. If jffs2 detects a bad block, does it set a flag in one of the bytes in
oob ?  I suppose we don't want to use byte 05 (bad block status) which was
set by the chip manufacturer.

Thanks.

Regards,
Steve




Thomas Gleixner <gleixner@xxxxxxx.com on 02/11/2002 11:28:09 AM

Please respond to gleixner@xxxxxxx.de

Sent by:  owner-jffs-dev@xxxxxxx.com


To:   David Woodhouse <dwmw2@xxxxxxx.org>
cc:   jffs-dev@xxxxxxx.org

Subject:  Re: NAND flash and JFFS(2)

On Monday, 11. February 2002 16:48, Thomas Gleixner wrote:

> I reflected this question again and we should do this very careful before
> implemetation. If we choose the same layout, somebody would be able to
> implement the SmartMedia DOS fs on top of SmartMedia and raw NAND flash.
> I personally have not interest in this fs, it's ok for MP3 players and
> digicams but not for industrial use.

I had a look at the nand driver, where we have to do some changes anyway to

support a different ECC address. To get the flexibility to use either a
JFFS2
specific ECC scheme or a different scheme like the SmartMedia DOS-FAT i
will
add a array to the nand structure, which holds the positions of the ECC
bytes
inside the spare area and a flag, which can be used to support the virtual
pagesize of 512 Byte for small NAND devices (if anybody is going to
implement
this).
The filesystem driver can set the ECC byte positions, so they match it's
requirements. We could add config options to select a default ECC scheme,
so
we have access to the chip as char device too. I'm not sure if we need this

really.
So we have the flexibility to do what we want and we don't prevent anybody
from implementing a different system.

I will try it with the following scheme tonight:

SmartMedia and raw NAND 512 byte pagesize
Byte 0-3        ECC part 1
Byte 4           page data valid flag
Byte 5           bad block status
Byte 6-7        ECC part 2
Byte 8-15      cleanmarker

SmartMedia and raw NAND 256 Byte pagesize
Byte 0-2        ECC
Byte 3           spare
Byte 4           page data valid flag
Byte 5           bad block status
Byte 6-7        cleanmarker

I have both card types so i can verify that it works.

Thomas
__________________________________________________
Thomas Gleixner, autronix automation GmbH
auf dem berg 3, d-88690 uhldingen-muehlhofen
fon: +49 7556 919891 , fax: +49 7556 919886
mail: gleixner@xxxxxxx.de">http://www.autronix.de

To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo@xxxxxxx.com





To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo@xxxxxxx.com