]> git.sur5r.net Git - u-boot/blobdiff - cpu/ppc4xx/ndfc.c
Sync'd u-boot-net with mainline
[u-boot] / cpu / ppc4xx / ndfc.c
index 09aac38f488e6a61f8c34b0552cf23175ec66a1a..398457726f426b3898ff794b6ebcd1018eaf3f76 100644 (file)
 
 #include <common.h>
 
-#if (CONFIG_COMMANDS & CFG_CMD_NAND) && !defined(CFG_NAND_LEGACY) && \
+#if defined(CONFIG_CMD_NAND) && !defined(CFG_NAND_LEGACY) && \
        (defined(CONFIG_440EP) || defined(CONFIG_440GR) ||           \
-        defined(CONFIG_440EPX) || defined(CONFIG_440GRX))
+        defined(CONFIG_440EPX) || defined(CONFIG_440GRX) ||         \
+        defined(CONFIG_405EZ))
 
 #include <nand.h>
 #include <linux/mtd/ndfc.h>
 #include <linux/mtd/nand_ecc.h>
 #include <asm/processor.h>
 #include <asm/io.h>
-#include <ppc440.h>
+#include <ppc4xx.h>
 
 static u8 hwctl = 0;
 
@@ -210,8 +211,7 @@ int board_nand_init(struct nand_chip *nand)
        /*
         * Setup EBC (CS0 only right now)
         */
-       mtdcr(ebccfga, xbcfg);
-       mtdcr(ebccfgd, 0xb8400000);
+       mtebc(EBC0_CFG, 0xb8400000);
 
        mtebc(pb0cr, CFG_EBC_PB0CR);
        mtebc(pb0ap, CFG_EBC_PB0AP);