0001 # SPDX-License-Identifier: GPL-2.0-only
0002
0003 menu "NAND"
0004
0005 config MTD_NAND_CORE
0006 tristate
0007
0008 source "drivers/mtd/nand/onenand/Kconfig"
0009 source "drivers/mtd/nand/raw/Kconfig"
0010 source "drivers/mtd/nand/spi/Kconfig"
0011
0012 menu "ECC engine support"
0013
0014 config MTD_NAND_ECC
0015 bool
0016 select MTD_NAND_CORE
0017
0018 config MTD_NAND_ECC_SW_HAMMING
0019 bool "Software Hamming ECC engine"
0020 default y if MTD_RAW_NAND
0021 select MTD_NAND_ECC
0022 help
0023 This enables support for software Hamming error
0024 correction. This correction can correct up to 1 bit error
0025 per chunk and detect up to 2 bit errors. While it used to be
0026 widely used with old parts, newer NAND chips usually require
0027 more strength correction and in this case BCH or RS will be
0028 preferred.
0029
0030 config MTD_NAND_ECC_SW_HAMMING_SMC
0031 bool "NAND ECC Smart Media byte order"
0032 depends on MTD_NAND_ECC_SW_HAMMING
0033 default n
0034 help
0035 Software ECC according to the Smart Media Specification.
0036 The original Linux implementation had byte 0 and 1 swapped.
0037
0038 config MTD_NAND_ECC_SW_BCH
0039 bool "Software BCH ECC engine"
0040 select BCH
0041 select MTD_NAND_ECC
0042 default n
0043 help
0044 This enables support for software BCH error correction. Binary BCH
0045 codes are more powerful and cpu intensive than traditional Hamming
0046 ECC codes. They are used with NAND devices requiring more than 1 bit
0047 of error correction.
0048
0049 config MTD_NAND_ECC_MXIC
0050 bool "Macronix external hardware ECC engine"
0051 depends on HAS_IOMEM
0052 select MTD_NAND_ECC
0053 help
0054 This enables support for the hardware ECC engine from Macronix.
0055
0056 config MTD_NAND_ECC_MEDIATEK
0057 tristate "Mediatek hardware ECC engine"
0058 depends on HAS_IOMEM
0059 depends on ARCH_MEDIATEK || COMPILE_TEST
0060 select MTD_NAND_ECC
0061 help
0062 This enables support for the hardware ECC engine from Mediatek.
0063
0064 endmenu
0065
0066 endmenu