From: Stefan Roese Date: Wed, 20 May 2009 08:58:03 +0000 (+0200) Subject: nand: Fix problem with ECC ordering for PPC4xx NDFC platforms X-Git-Tag: v2009.06-rc3~24 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=f40f6db278f602b55820693634a7256b0b4e4b80;p=u-boot nand: Fix problem with ECC ordering for PPC4xx NDFC platforms This patch enables Smart Media (SMC) ECC byte ordering which is used on the PPC4xx NAND FLASH controller (NDFC). Without this patch we have incompatible ECC byte ordering to the Linux kernel NDFC driver. Signed-off-by: Stefan Roese Acked-by: Scott Wood --- diff --git a/drivers/mtd/nand/nand_ecc.c b/drivers/mtd/nand/nand_ecc.c index 94923b9524..463f9cb4d4 100644 --- a/drivers/mtd/nand/nand_ecc.c +++ b/drivers/mtd/nand/nand_ecc.c @@ -48,6 +48,11 @@ #include #include +/* The PPC4xx NDFC uses Smart Media (SMC) bytes order */ +#ifdef CONFIG_NAND_NDFC +#define CONFIG_MTD_NAND_ECC_SMC +#endif + /* * NAND-SPL has no sofware ECC for now, so don't include nand_calculate_ecc(), * only nand_correct_data() is needed