forked from Minki/linux
mtd: rawnand: cafe: Set the NAND_NO_BBM_QUIRK flag
We have a dummy block_bad() implementation returning 0. Let's set the NAND_NO_BBM_QUIRK flag and let the core take care of that. Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Link: https://lore.kernel.org/linux-mtd/20200511064917.6255-2-boris.brezillon@collabora.com
This commit is contained in:
parent
ec7cfc3d76
commit
8420c68a16
@ -546,11 +546,6 @@ static int cafe_nand_write_page_lowlevel(struct nand_chip *chip,
|
||||
return nand_prog_page_end_op(chip);
|
||||
}
|
||||
|
||||
static int cafe_nand_block_bad(struct nand_chip *chip, loff_t ofs)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* F_2[X]/(X**6+X+1) */
|
||||
static unsigned short gf64_mul(u8 a, u8 b)
|
||||
{
|
||||
@ -718,10 +713,8 @@ static int cafe_nand_probe(struct pci_dev *pdev,
|
||||
/* Enable the following for a flash based bad block table */
|
||||
cafe->nand.bbt_options = NAND_BBT_USE_FLASH;
|
||||
|
||||
if (skipbbt) {
|
||||
cafe->nand.options |= NAND_SKIP_BBTSCAN;
|
||||
cafe->nand.legacy.block_bad = cafe_nand_block_bad;
|
||||
}
|
||||
if (skipbbt)
|
||||
cafe->nand.options |= NAND_SKIP_BBTSCAN | NAND_NO_BBM_QUIRK;
|
||||
|
||||
if (numtimings && numtimings != 3) {
|
||||
dev_warn(&cafe->pdev->dev, "%d timing register values ignored; precisely three are required\n", numtimings);
|
||||
|
Loading…
Reference in New Issue
Block a user