Commit e8495069 authored by Paul Cercueil's avatar Paul Cercueil Committed by Miquel Raynal
Browse files

mtd: rawnand: ingenic: Move BBTs out of ECC area



The generic layout for BBT markers will most likely overlap with our
ECC bytes in the OOB, so move the BBT markers outside the OOB area.

Signed-off-by: default avatarPaul Cercueil <paul@crapouillou.net>
Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
parent 2a738583
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -282,6 +282,13 @@ static int ingenic_nand_attach_chip(struct nand_chip *chip)
		return -EINVAL;
	}

	/*
	 * The generic layout for BBT markers will most likely overlap with our
	 * ECC bytes in the OOB, so move the BBT markers outside the OOB area.
	 */
	if (chip->bbt_options & NAND_BBT_USE_FLASH)
		chip->bbt_options |= NAND_BBT_NO_OOB;

	/* For legacy reasons we use a different layout on the qi,lb60 board. */
	if (of_machine_is_compatible("qi,lb60"))
		mtd_set_ooblayout(mtd, &qi_lb60_ooblayout_ops);