aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
authorMaxim Levitsky <maximlevitsky@gmail.com>2010-03-19 11:22:54 -0400
committerDavid Woodhouse <David.Woodhouse@intel.com>2010-03-26 11:26:27 -0400
commite5f710cfc6947e64672b7205f7992515868c7782 (patch)
treec72c3262e6a65b59f067b61cd910697edc071ecb /drivers/mtd
parentca7081d96e39ea276892f0577f9cf37568547e88 (diff)
mtd: nand: split out ECC module
This way drivers could use ecc routines without depedency on whole nand Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/Kconfig3
-rw-r--r--drivers/mtd/nand/Kconfig19
-rw-r--r--drivers/mtd/nand/Makefile3
3 files changed, 16 insertions, 9 deletions
diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
index dbee14d37224..e652080bce5d 100644
--- a/drivers/mtd/Kconfig
+++ b/drivers/mtd/Kconfig
@@ -307,8 +307,9 @@ config SSFDC
307 307
308config SM_FTL 308config SM_FTL
309 tristate "SmartMedia/xD new translation layer" 309 tristate "SmartMedia/xD new translation layer"
310 depends on EXPERIMENTAL && BLOCK && MTD_NAND 310 depends on EXPERIMENTAL && BLOCK
311 select MTD_BLKDEVS 311 select MTD_BLKDEVS
312 select MTD_NAND_ECC
312 help 313 help
313 This enables new and very EXPERMENTAL support for SmartMedia/xD 314 This enables new and very EXPERMENTAL support for SmartMedia/xD
314 FTL (Flash translation layer). 315 FTL (Flash translation layer).
diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig
index 164bd56b9d1a..b712aedd89fb 100644
--- a/drivers/mtd/nand/Kconfig
+++ b/drivers/mtd/nand/Kconfig
@@ -2,11 +2,23 @@ menuconfig MTD_NAND
2 tristate "NAND Device Support" 2 tristate "NAND Device Support"
3 depends on MTD 3 depends on MTD
4 select MTD_NAND_IDS 4 select MTD_NAND_IDS
5 select MTD_NAND_ECC
5 help 6 help
6 This enables support for accessing all type of NAND flash 7 This enables support for accessing all type of NAND flash
7 devices. For further information see 8 devices. For further information see
8 <http://www.linux-mtd.infradead.org/doc/nand.html>. 9 <http://www.linux-mtd.infradead.org/doc/nand.html>.
9 10
11config MTD_NAND_ECC
12 tristate
13
14config MTD_NAND_ECC_SMC
15 bool "NAND ECC Smart Media byte order"
16 depends on MTD_NAND_ECC
17 default n
18 help
19 Software ECC according to the Smart Media Specification.
20 The original Linux implementation had byte 0 and 1 swapped.
21
10if MTD_NAND 22if MTD_NAND
11 23
12config MTD_NAND_VERIFY_WRITE 24config MTD_NAND_VERIFY_WRITE
@@ -18,13 +30,6 @@ config MTD_NAND_VERIFY_WRITE
18 device thinks the write was successful, a bit could have been 30 device thinks the write was successful, a bit could have been
19 flipped accidentally due to device wear or something else. 31 flipped accidentally due to device wear or something else.
20 32
21config MTD_NAND_ECC_SMC
22 bool "NAND ECC Smart Media byte order"
23 default n
24 help
25 Software ECC according to the Smart Media Specification.
26 The original Linux implementation had byte 0 and 1 swapped.
27
28config MTD_SM_COMMON 33config MTD_SM_COMMON
29 tristate 34 tristate
30 default n 35 default n
diff --git a/drivers/mtd/nand/Makefile b/drivers/mtd/nand/Makefile
index 5fbd1f83afb6..04bccf9d7b53 100644
--- a/drivers/mtd/nand/Makefile
+++ b/drivers/mtd/nand/Makefile
@@ -2,7 +2,8 @@
2# linux/drivers/nand/Makefile 2# linux/drivers/nand/Makefile
3# 3#
4 4
5obj-$(CONFIG_MTD_NAND) += nand.o nand_ecc.o 5obj-$(CONFIG_MTD_NAND) += nand.o
6obj-$(CONFIG_MTD_NAND_ECC) += nand_ecc.o
6obj-$(CONFIG_MTD_NAND_IDS) += nand_ids.o 7obj-$(CONFIG_MTD_NAND_IDS) += nand_ids.o
7obj-$(CONFIG_MTD_SM_COMMON) += sm_common.o 8obj-$(CONFIG_MTD_SM_COMMON) += sm_common.o
8 9