diff options
author | Boris Brezillon <boris.brezillon@collabora.com> | 2020-04-18 22:42:17 +0300 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2020-05-10 22:16:01 +0300 |
commit | ce446b4b2d803cf62de2e74b1fbda8758e4835bd (patch) | |
tree | 4c78cb5fcbf2b2fee6dc4a124bb4d73a38311c5e /drivers/mtd/nand/raw/vf610_nfc.c | |
parent | 4ba246d7a365b8049892d852ab00d8bd707dc0e6 (diff) | |
download | linux-ce446b4b2d803cf62de2e74b1fbda8758e4835bd.tar.xz |
mtd: rawnand: Take check_only into account
->exec_op() is passed a check_only argument that encodes when the
controller should just check whether the operation is supported or not
without executing it. Some controllers simply ignore this arguments,
others don't but keep modifying some of the registers before returning.
Let's fix all those drivers.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20200418194217.1016060-1-boris.brezillon@collabora.com
Diffstat (limited to 'drivers/mtd/nand/raw/vf610_nfc.c')
-rw-r--r-- | drivers/mtd/nand/raw/vf610_nfc.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mtd/nand/raw/vf610_nfc.c b/drivers/mtd/nand/raw/vf610_nfc.c index 6b399a75f9ae..bd9e16de78a2 100644 --- a/drivers/mtd/nand/raw/vf610_nfc.c +++ b/drivers/mtd/nand/raw/vf610_nfc.c @@ -502,7 +502,9 @@ static int vf610_nfc_exec_op(struct nand_chip *chip, const struct nand_operation *op, bool check_only) { - vf610_nfc_select_target(chip, op->cs); + if (!check_only) + vf610_nfc_select_target(chip, op->cs); + return nand_op_parser_exec_op(chip, &vf610_nfc_op_parser, op, check_only); } |