Merge branch 'master' of rsync://rsync.denx.de/git/u-boot
[platform/kernel/u-boot.git] / drivers / nand / nand_bbt.c
index dfa88a3..aaa9400 100644 (file)
@@ -54,7 +54,7 @@
 
 #include <common.h>
 
-#if (CONFIG_COMMANDS & CFG_CMD_NAND)
+#if (CONFIG_COMMANDS & CFG_CMD_NAND) && !defined(CFG_NAND_LEGACY)
 
 #include <malloc.h>
 #include <linux/mtd/compat.h>
@@ -261,8 +261,6 @@ static void create_bbt (struct mtd_info *mtd, uint8_t *buf, struct nand_bbt_desc
        loff_t from;
        size_t readlen, ooblen;
 
-       printk (KERN_INFO "Scanning device for bad blocks\n");
-
        if (bd->options & NAND_BBT_SCANALLPAGES)
                len = 1 << (this->bbt_erase_shift - this->page_shift);
        else {
@@ -298,8 +296,6 @@ static void create_bbt (struct mtd_info *mtd, uint8_t *buf, struct nand_bbt_desc
                for (j = 0; j < len; j++) {
                        if (check_pattern (&buf[j * scanlen], scanlen, mtd->oobblock, bd)) {
                                this->bbt[i >> 3] |= 0x03 << (i & 0x6);
-                               printk (KERN_WARNING "Bad eraseblock %d at 0x%08x\n",
-                                       i >> 1, (unsigned int) from);
                                break;
                        }
                }