]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
mtd: nand: rename the cellinfo to bits_per_cell
authorHuang Shijie <b32955@freescale.com>
Wed, 25 Sep 2013 06:58:11 +0000 (14:58 +0800)
committerBrian Norris <computersforpeace@gmail.com>
Tue, 15 Oct 2013 20:56:39 +0000 (13:56 -0700)
commit56c1b13ca458074cef2c3acee62c3c509b0e59f5
tree3af03091c802e76d9e7157b2abb91cd74075e111
parent01da63fe2a5ad51aaa0db00dd8984a5731806c86
mtd: nand: rename the cellinfo to bits_per_cell

The @cellinfo fields contains unused information, such as write caching,
internal chip numbering, etc. But we only use it to check the SLC or MLC.

This patch tries to make it more clear and simple, renames the @cellinfo
to @bits_per_cell.

In order to avoiding the bisect issue, this patch also does the following
changes:
  (0) add a macro NAND_CI_CELLTYPE_SHIFT to avoid the hardcode.

  (1) add a helper to parse out the cell type : nand_get_bits_per_cell()

  (2) parse out the cell type for extended-ID chips and the full-id nand chips.

Signed-off-by: Huang Shijie <b32955@freescale.com>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
drivers/mtd/nand/nand_base.c
include/linux/mtd/nand.h