summaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
authorColin Ian King <colin.i.king@gmail.com>2021-12-06 00:07:29 +0100
committerMiquel Raynal <miquel.raynal@bootlin.com>2021-12-09 17:29:51 +0100
commitdf87a1efb8372bc119abb5757a458d688ae2d580 (patch)
treec83a49efb48da1cbd029fa2b2e3a7dde492a72cd /drivers/mtd
parentmtd: rawnand: mpc5121: Remove unused variable in ads5121_select_chip() (diff)
downloadlinux-df87a1efb8372bc119abb5757a458d688ae2d580.tar.xz
linux-df87a1efb8372bc119abb5757a458d688ae2d580.zip
mtd: onenand: remove redundant variable ooblen
Variable ooblen is being initialized with a value that is never read. The variable is never used after this, so it is redundant and can be removed. Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Link: https://lore.kernel.org/linux-mtd/20211205230729.79337-1-colin.i.king@gmail.com
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/nand/onenand/onenand_bbt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mtd/nand/onenand/onenand_bbt.c b/drivers/mtd/nand/onenand/onenand_bbt.c
index def89f108007..b17315f8e1d4 100644
--- a/drivers/mtd/nand/onenand/onenand_bbt.c
+++ b/drivers/mtd/nand/onenand/onenand_bbt.c
@@ -60,7 +60,7 @@ static int create_bbt(struct mtd_info *mtd, uint8_t *buf, struct nand_bbt_descr
int i, j, numblocks, len, scanlen;
int startblock;
loff_t from;
- size_t readlen, ooblen;
+ size_t readlen;
struct mtd_oob_ops ops;
int rgn;
@@ -69,7 +69,7 @@ static int create_bbt(struct mtd_info *mtd, uint8_t *buf, struct nand_bbt_descr
len = 2;
/* We need only read few bytes from the OOB area */
- scanlen = ooblen = 0;
+ scanlen = 0;
readlen = bd->len;
/* chip == -1 case only */