Merge with git://www.denx.de/git/u-boot.git#testing-USB
[oweals/u-boot.git] / drivers / nand / nand_ecc.c
index 4e610c1123e5f5b458805c15a7d230699b5645c9..f33be9655d36150cefadc990f88a8b4b6cf8f077 100644 (file)
@@ -37,8 +37,7 @@
 
 #include <common.h>
 
-#ifdef CONFIG_NEW_NAND_CODE
-#if (CONFIG_COMMANDS & CFG_CMD_NAND)
+#if (CONFIG_COMMANDS & CFG_CMD_NAND) && !defined(CFG_NAND_LEGACY)
 
 #include<linux/mtd/mtd.h>
 /*
@@ -243,5 +242,3 @@ int nand_correct_data(struct mtd_info *mtd, u_char *dat, u_char *read_ecc, u_cha
 }
 
 #endif /* CONFIG_COMMANDS & CFG_CMD_NAND */
-#endif /* CONFIG_NEW_NAND_CODE */
-