Skip to contentSkip to conversation

Question on how NAND flash BBT is stored in the chip

DISCUSSION Rutger Hofman 1 participant 2 messages Oct 16, 2008 – Oct 17, 2008 1 message not in the archive Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

Good afternoon list,

I have a question how the BBT (bad block table) is stored in MTD NAND devices. I googled for a while, and browsed the code, but I am still not sure.

The question:
Is the BBT stored/retrieved using a spare layout? Is ECC generation/correction done for it?

This question derives from the question above: is the BBT marker pattern stored within a spare layout (with slots for ECC, bad block markers etc)? Or is it written verbatim (raw and unmangled) into the spare area?

If no ECC is used for the BBT, is that for a reason?

Thanks for the information,

Rutger Hofman
VU Amsterdam

A message that is not in the archive (sent off-list or not yet received): [email protected]

#2 lore raw
Quoted 9 lines · Du Zhongdong

On Thu, Oct 16, 2008 at 10:35 PM, Rutger Hofman <[email protected] <mailto:[email protected]>> wrote:

Good afternoon list,

I have a question how the BBT (bad block table) is stored in MTD NAND devices. I googled for a while, and browsed the code, but I am still not sure.

Quoted 5 lines

The question:
Is the BBT stored/retrieved using a spare layout? Is ECC generation/correction done for it?

I'm not quite sure about what you mean by "using a spare layout", but I think bbt is stored in the main area of the specific page(the member "int pages[NAND_MAX_CHIPS" in struct nand_bbt_descr).

With 'spare layout' I mean the thingy that does auto-placement etc, and wraps up ECC, bad block mark(s), and user data into the spare area.

Quoted 9 lines

the function scan_write_bbt calls mtd->write_oob with struct mtd_oob_ops.mode = MTD_OOB_PLACE, tracking down this procedure I think the oob data does not change its layout when written to NAND flash.

hope this information might be of some help to you :)

This question derives from the question above: is the BBT marker pattern stored within a spare layout (with slots for ECC, bad block markers etc)? Or is it written verbatim (raw and unmangled) into the spare area?

Thanks. When browsing the code, I thought as much, but I couldn't absolutely make sure whether the spare is mangled or not.

So this leaves the question: the BBT itself doesn't seem to use ECC. Is there a reason why not? Wouldn't it be better if it does?

Thanks,

Rutger Hofman
VU Amsterdam