diff options
author | Boris Brezillon <boris.brezillon@bootlin.com> | 2018-09-06 15:05:19 +0300 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2018-10-03 12:12:25 +0300 |
commit | 00da2ea97229946450c8145d680db480b5da1f94 (patch) | |
tree | 185839a4fbbf4bb8c377c309958b7607ae7fe29c /drivers/mtd/nand/raw/r852.c | |
parent | af37d2c3a8c7a05cf5b0fe6b61e2a6b9e357928b (diff) | |
download | linux-00da2ea97229946450c8145d680db480b5da1f94.tar.xz |
mtd: rawnand: Pass a nand_chip object to ecc->correct()
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.
Now is ecc->correct()'s turn.
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Diffstat (limited to 'drivers/mtd/nand/raw/r852.c')
-rw-r--r-- | drivers/mtd/nand/raw/r852.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/mtd/nand/raw/r852.c b/drivers/mtd/nand/raw/r852.c index f58d633ec062..7673aa140009 100644 --- a/drivers/mtd/nand/raw/r852.c +++ b/drivers/mtd/nand/raw/r852.c @@ -465,14 +465,14 @@ static int r852_ecc_calculate(struct nand_chip *chip, const uint8_t *dat, * Correct the data using ECC, hw did almost everything for us */ -static int r852_ecc_correct(struct mtd_info *mtd, uint8_t *dat, - uint8_t *read_ecc, uint8_t *calc_ecc) +static int r852_ecc_correct(struct nand_chip *chip, uint8_t *dat, + uint8_t *read_ecc, uint8_t *calc_ecc) { uint32_t ecc_reg; uint8_t ecc_status, err_byte; int i, error = 0; - struct r852_device *dev = r852_get_dev(mtd); + struct r852_device *dev = r852_get_dev(nand_to_mtd(chip)); if (dev->card_unstable) return 0; |