diff options
author | Colin Ian King <colin.king@canonical.com> | 2018-01-19 07:59:54 +0000 |
---|---|---|
committer | Boris Brezillon <boris.brezillon@free-electrons.com> | 2018-01-19 09:40:10 +0100 |
commit | e06a181b5dad6b1904e09e62c924868d7cfeacb6 (patch) | |
tree | 56b636eb45bb8ff37bb9de6409e492b039a70b6c /drivers/mtd | |
parent | a76497dc49518bc162ebc8ee4f139a075b9f9ad0 (diff) | |
download | op-kernel-dev-e06a181b5dad6b1904e09e62c924868d7cfeacb6.zip op-kernel-dev-e06a181b5dad6b1904e09e62c924868d7cfeacb6.tar.gz |
mtd: nand: marvell: remove redundant variable 'oob_len'
Variable oob_len is assigned and never read, hence it is redundant and
can be removed.
Cleans up clang warnings:
drivers/mtd/nand/marvell_nand.c:1356:6: warning: Value stored to 'oob_len'
during its initialization is never read
drivers/mtd/nand/marvell_nand.c:1369:4: warning: Value stored to 'oob_len'
is never read
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Miquel Raynal <miquel.raynal@free-electrons.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/nand/marvell_nand.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/mtd/nand/marvell_nand.c b/drivers/mtd/nand/marvell_nand.c index 4bd53b3..f15ab37 100644 --- a/drivers/mtd/nand/marvell_nand.c +++ b/drivers/mtd/nand/marvell_nand.c @@ -1353,7 +1353,6 @@ static int marvell_nfc_hw_ecc_bch_write_page_raw(struct mtd_info *mtd, int data_len = lt->data_bytes; int spare_len = lt->spare_bytes; int ecc_len = lt->ecc_bytes; - int oob_len = spare_len + ecc_len; int spare_offset = 0; int ecc_offset = (lt->full_chunk_cnt * lt->spare_bytes) + lt->last_spare_bytes; @@ -1366,7 +1365,6 @@ static int marvell_nfc_hw_ecc_bch_write_page_raw(struct mtd_info *mtd, data_len = lt->last_data_bytes; spare_len = lt->last_spare_bytes; ecc_len = lt->last_ecc_bytes; - oob_len = spare_len + ecc_len; } /* Point to the column of the next chunk */ |