mtd: rawnand: Pass a nand_chip object to chip->waitfunc()

Let's make the raw NAND API consistent by patching all helpers and
hooks to take a nand_chip object instead of an mtd_info one or
remove the mtd_info object when both are passed.

Let's tackle the chip->waitfunc() hook.

Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
This commit is contained in:
Boris Brezillon
2018-09-06 14:05:29 +02:00
committed by Miquel Raynal
parent 5295cf2e04
commit f1d46942e8
15 changed files with 42 additions and 57 deletions

View File

@@ -945,7 +945,7 @@ static int atmel_hsmc_nand_pmecc_write_pg(struct nand_chip *chip,
dev_err(nc->base.dev, "Failed to program NAND page (err = %d)\n",
ret);
status = chip->waitfunc(mtd, chip);
status = chip->waitfunc(chip);
if (status & NAND_STATUS_FAIL)
return -EIO;