]> git.karo-electronics.de Git - linux-beck.git/commitdiff
mtd: nand: denali: remove unused struct member totalblks, blksperchip
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Wed, 9 Nov 2016 04:35:25 +0000 (13:35 +0900)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Sat, 19 Nov 2016 08:38:59 +0000 (09:38 +0100)
The denali->blksperchip is set, but not referenced any more.  The
denali->totalblks is used only for calculating denali->blksperchip.
Both of them are unneeded.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/nand/denali.c
drivers/mtd/nand/denali.h

index c525995f927c66ad28d2074290017c8202972d47..98b21d230e629089c8da1151d1965e05c833f1ec 100644 (file)
@@ -1573,14 +1573,6 @@ int denali_init(struct denali_nand_info *denali)
        denali->nand.ecc.bytes *= denali->devnum;
        denali->nand.ecc.strength *= denali->devnum;
 
-       /*
-        * Let driver know the total blocks number and how many blocks
-        * contained by each nand chip. blksperchip will help driver to
-        * know how many blocks is taken by FW.
-        */
-       denali->totalblks = mtd->size >> denali->nand.phys_erase_shift;
-       denali->blksperchip = denali->totalblks / denali->nand.numchips;
-
        /* override the default read operations */
        denali->nand.ecc.size = ECC_SECTOR_SIZE * denali->devnum;
        denali->nand.ecc.read_page = denali_read_page;
index 7c0800d9dd4c6a8fcfe4c65eae9e167654d7c038..ea22191e85157c1603c798fef6147a4934c9f50a 100644 (file)
@@ -462,8 +462,6 @@ struct denali_nand_info {
        int irq;
 
        uint32_t devnum;        /* represent how many nands connected */
-       uint32_t totalblks;
-       uint32_t blksperchip;
        uint32_t bbtskipbytes;
        uint32_t max_banks;
 };