mtd: gpmi: add sanity check for the ECC
authorHuang Shijie <b32955@freescale.com>
Tue, 29 Jan 2013 01:23:38 +0000 (09:23 +0800)
committerArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Mon, 4 Feb 2013 08:28:02 +0000 (10:28 +0200)
commit92d0e09abeebdd3f699c9f12401a9e3998a20546
treefa51378318368e5dd1471e2f82b061e007dfb6f8
parent9ff16f0833806b6b59aaf0cc158fa6e42f24d7e4
mtd: gpmi: add sanity check for the ECC

We do the check based on the following two facts:

[1] The mx23/mx28 can only support 20-bits ECC, while the mx6
    can supports 40-bits ECC.

[2] The mx23/mx28 can only support the GF13, while the mx6
    can supports GF13 and GF14.

Signed-off-by: Huang Shijie <b32955@freescale.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
drivers/mtd/nand/gpmi-nand/gpmi-nand.c
drivers/mtd/nand/gpmi-nand/gpmi-nand.h