Handle eraseblocks containing the bad-block table in UBI

Bogdan Harjoc harjoc at gmail.com
Sat Jan 13 04:46:45 PST 2018

On Fri, Jan 12, 2018 at 10:52 PM, Richard Weinberger
<richard.weinberger at gmail.com> wrote:
> Usually blocks containing the BBT are also marked as bad to avoid the
> problem you're facing.
> So, yes UBI should not see these PEBs because they should look like bad blocks.
> Is this a kernel with vendor hackery?

It is, at least the nand probing code adds its own nand_bbt_descr
structs. Since the issue goes away by adding an

if (ec_hdr->magic == 'Bbt0' or '1bbT')

in ubi_io_read_ec_hdr(), I will see where the bad-block status for the
bbt PEBs gets lost.

Thank you,

More information about the linux-mtd mailing list