diff options
author | Boris Brezillon <bbrezillon@kernel.org> | 2018-10-29 11:58:29 +0100 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2019-04-08 10:21:16 +0200 |
commit | 32813e288414fecce18f37f8f0d0414a64b45c56 (patch) | |
tree | b8b5296f17bfcf1a266e0261fafc12fab5f337a1 /drivers/mtd/nand/raw/hisi504_nand.c | |
parent | 6c836d515ff85e333488692c67969f714654a1c6 (diff) |
mtd: rawnand: Get rid of chip->numchips
The same information is provided by nanddev_ntargets().
Signed-off-by: Boris Brezillon <bbrezillon@kernel.org>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Frieder Schrempf <frieder.schrempf@kontron.de>
Diffstat (limited to 'drivers/mtd/nand/raw/hisi504_nand.c')
-rw-r--r-- | drivers/mtd/nand/raw/hisi504_nand.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/nand/raw/hisi504_nand.c b/drivers/mtd/nand/raw/hisi504_nand.c index f3f9aa160cff..e4526fff9da4 100644 --- a/drivers/mtd/nand/raw/hisi504_nand.c +++ b/drivers/mtd/nand/raw/hisi504_nand.c @@ -849,7 +849,7 @@ static int hisi_nfc_resume(struct device *dev) struct hinfc_host *host = dev_get_drvdata(dev); struct nand_chip *chip = &host->chip; - for (cs = 0; cs < chip->numchips; cs++) + for (cs = 0; cs < nanddev_ntargets(&chip->base); cs++) hisi_nfc_send_cmd_reset(host, cs); hinfc_write(host, SET_HINFC504_PWIDTH(HINFC504_W_LATCH, HINFC504_R_LATCH, HINFC504_RW_LATCH), HINFC504_PWIDTH); |