[PATCH] mtd: nand: omap: save Bad-Block-Table (BBT) on device

Gupta, Pekon pekon at ti.com
Thu Jul 24 10:56:14 PDT 2014


>From: Brian Norris [mailto:computersforpeace at gmail.com]
>>On Wed, Jul 23, 2014 at 05:27:46PM -0300, ezequiel at vanguardiasur.com.ar wrote:
[...]
>> In fact, you do have a simple way to solve this. Just support BBT through
>> the "nand-on-flash-bbt" devicetree property, so a user can tell if his flash
>> has a BBT or not. See pxa3xx-nand.c, which should be correct.
>
>Yes, you can use the 'nand-on-flash-bbt' property, and that probably
>makes the most sense.
>
>The only real backwards-compatibility concern you'd have for
>unconditionally enabling on-flash BBT (like in this patch) is if you had
>previous file system data in the last 4 blocks; nand_bbt will just
>clobber it, breaking your file system. For this reason, using DT is
>probably a good idea -- you're opting in, rather than being forced in by
>a kernel upgrade.
>
>Beyond the backwards-compatibility concern, you still have other
>concerns about on-flash BBT's robustness. Limiting yourself to a region
>of 4 blocks is one potential issue. There are others (e.g., lack of CRC
>protection), but none that have been real show-stoppers. I have a few
>generations of products running it here.
>
>BTW, there's a recent thread about GPMI and its "bad block mark
>swapping", which has led to somebody wanting a new DT binding for
>'on-flash-bbt-no-oob-bbm' or something like that, to mirror the
>(excellently named -- by me) NAND_BBT_NO_OOB_BBM option. I'm not real
>happy with adding a random assortment of configurable BBT flags into the
>DT ABI, without fully describing and standardizing the BBT format. It's
>kind of a vacuous target right now, which is just defined by the
>70%-baked solution in our current implementation... (I guess I need to
>go reply to the GPMI/NO_OOB_BBM thread soon!)
>
>Brian
>
>[1] http://lists.infradead.org/pipermail/linux-mtd/2014-March/052666.html
>    http://lists.infradead.org/pipermail/linux-mtd/2014-March/052796.html
>    http://lists.infradead.org/pipermail/linux-mtd/2014-March/052988.html

Thanks much to both of you.
Yes, "nand-on-flash-bbt" devicetree property seems the correct approach.
I'll study the above threads, and then get back with appropriate patch.
So, please ignore this patch.

with regards, pekon



More information about the linux-mtd mailing list