From 685b99ad165ddb7eaa64962e66342f6bb1d48b30 Mon Sep 17 00:00:00 2001 From: Holger Freyther Date: Wed, 19 Nov 2008 17:10:51 +0000 Subject: From 5ee1ee9e1c8a652b0f9cde72ad5e547db87d4d67 Mon Sep 17 00:00:00 2001 Subject: [PATCH] [gta02] Disable hardware ECC unless we get instructed to enable it This is restoring the old behavior in regard to ECC. Even if hardware ECC was compiled in we didn't use it. Make this a runtime option. If the bootloader passes hardware_ecc we will enable the hardware ECC for real. --- drivers/mtd/nand/s3c2410.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c index a268575b381..7f68d8c59bb 100644 --- a/drivers/mtd/nand/s3c2410.c +++ b/drivers/mtd/nand/s3c2410.c @@ -744,7 +744,7 @@ static void s3c2410_nand_init_chip(struct s3c2410_nand_info *info, nmtd->mtd.owner = THIS_MODULE; nmtd->set = set; - if (hardware_ecc) { + if (!info->platform->software_ecc && hardware_ecc) { chip->ecc.calculate = s3c2410_nand_calculate_ecc; chip->ecc.correct = s3c2410_nand_correct_data; chip->ecc.mode = NAND_ECC_HW; -- cgit v1.2.3