]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: nand: complain loudly when chip->bits_per_cell is not correctly initialized
authorLothar Waßmann <LW@KARO-electronics.de>
Tue, 29 Aug 2017 10:17:13 +0000 (12:17 +0200)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Tue, 29 Aug 2017 16:23:50 +0000 (18:23 +0200)
commit9ccc3207d883714f4ca34f06160c071967b14eb1
treebf1eee410798935e7318f878f12be25f4696a729
parentb0852d3aa0baa3056cbad645113cc5d32a8f2aad
mtd: nand: complain loudly when chip->bits_per_cell is not correctly initialized

chip->bits_per_cell which is used to determine the NAND cell type
(SLC/MLC) should always have a value != 0.
Complain loudly if the value is 0 in nand_is_slc() to catch use before
correct initialization.

Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
include/linux/mtd/rawnand.h