diff options
author | ye xingchen <ye.xingchen@zte.com.cn> | 2022-09-01 10:45:54 +0300 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2022-09-21 11:38:47 +0300 |
commit | 4c5f69aea151dbd1977ad2cdd00ed0828e3a4888 (patch) | |
tree | d0a6b64574eb4e7a8cf3dea89ac90f2c563ccdfc /drivers/mtd | |
parent | c26ef845c04e45cebac8c21d8ce23270fa20ee3c (diff) | |
download | linux-4c5f69aea151dbd1977ad2cdd00ed0828e3a4888.tar.xz |
mtd: rawnand: cadence: Remove an unneeded result variable
Return the value cadence_nand_set_access_width16() directly instead of
storing it in another redundant variable.
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20220901074555.313266-1-ye.xingchen@zte.com.cn
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/nand/raw/cadence-nand-controller.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/mtd/nand/raw/cadence-nand-controller.c b/drivers/mtd/nand/raw/cadence-nand-controller.c index 0d72672f8b64..9dac3ca69d57 100644 --- a/drivers/mtd/nand/raw/cadence-nand-controller.c +++ b/drivers/mtd/nand/raw/cadence-nand-controller.c @@ -1979,7 +1979,6 @@ static int cadence_nand_force_byte_access(struct nand_chip *chip, bool force_8bit) { struct cdns_nand_ctrl *cdns_ctrl = to_cdns_nand_ctrl(chip->controller); - int status; /* * Callers of this function do not verify if the NAND is using a 16-bit @@ -1990,9 +1989,7 @@ static int cadence_nand_force_byte_access(struct nand_chip *chip, if (!(chip->options & NAND_BUSWIDTH_16)) return 0; - status = cadence_nand_set_access_width16(cdns_ctrl, !force_8bit); - - return status; + return cadence_nand_set_access_width16(cdns_ctrl, !force_8bit); } static int cadence_nand_cmd_opcode(struct nand_chip *chip, |