All of lore.kernel.org
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] nand: current mainline show "new" startup output
Date: Mon, 13 Feb 2012 11:06:10 -0600	[thread overview]
Message-ID: <4F394302.30504@freescale.com> (raw)
In-Reply-To: <4F38C740.4050409@denx.de>

On 02/13/2012 02:18 AM, Heiko Schocher wrote:
> Hello Christian, Scott,
> 
> current mainline code of U-Boot:
> 
> commit 9a3aae22edf1eda6326cc51c28631ca5c23b7706
> Author: Christian Riesch <christian.riesch@omicron.at>
> Date:   Thu Feb 2 00:44:42 2012 +0000
> 
>     arm, davinci: Add support for the Calimain board from OMICRON electronics
> 
>     This patch adds support for the Calimain board from
>     OMICRON electronics GmbH. The board features a Texas Instruments AM1808
>     SoC, 128 MB DDR2 memory, and 64 MB NOR flash memory connected to CS2 and
>     CS3.
> 
>     Signed-off-by: Christian Riesch <christian.riesch@omicron.at>
> 
> shows now on startup the following printfs on the enbw_cmc board:
> 
> 
> 
> U-Boot 2011.12-00331-ga400f85 (Feb 13 2012 - 08:49:17)
> 
> I2C:   ready
> [...]
> NAND:  Bad block table found at page 65472, version 0x01
> Bad block table found at page 65408, version 0x01
> nand_read_bbt: Bad block at 0x000002980000
> nand_read_bbt: Bad block at 0x000003240000
> 128 MiB
> MMC:   davinci: 0
> 
> Found with "git bisect" the reason:
> 
> [hs at pollux u-boot]$ git bisect good
> 2a8e0fc8b3dc31a3c571e439fbf04b882c8986be is the first bad commit
> commit 2a8e0fc8b3dc31a3c571e439fbf04b882c8986be
> Author: Christian Hitz <christian.hitz@aizo.com>
> Date:   Wed Oct 12 09:32:02 2011 +0200
> 
>     nand: Merge changes from Linux nand driver
> 
>     [backport from linux commit 02f8c6aee8df3cdc935e9bdd4f2d020306035dbe]
> 
>     This patch synchronizes the nand driver with the Linux 3.0 state.
> 
>     Signed-off-by: Christian Hitz <christian.hitz@aizo.com>
>     Cc: Scott Wood <scottwood@freescale.com>
>     [scottwood at freescale.com: minor fixes]
>     Signed-off-by: Scott Wood <scottwood@freescale.com>
> 
> :040000 040000 5ab34f43b64379528b9ef2652c8481fdab1a927a b453a49035e179dfb5f31c3164a1b7d3d62d66d6 M      drivers
> :040000 040000 b59a7f3136da038b4b49c48cd0958e140a09ed66 a8fd298715a562fda0a350e6f732c1072ca7d410 M      include
> [hs at pollux u-boot]$
> 
> Looking in this patch, it seems to me, this is the "reason":
> 
> diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c
> index 758b53f..ed2640c 100644
> --- a/drivers/mtd/nand/nand_base.c
> +++ b/drivers/mtd/nand/nand_base.c
> [...]
> @@ -2992,9 +3145,10 @@ int nand_scan_tail(struct mtd_info *mtd)
> 
>         /* Check, if we should skip the bad block table scan */
>         if (chip->options & NAND_SKIP_BBTSCAN)
> -               chip->options |= NAND_BBT_SCANNED;
> +               return 0;
> 
> -       return 0;
> +       /* Build bad block table */
> +       return chip->scan_bbt(mtd);
>  }
> 
>  /**
> 
> ... This printfs in the startoutput are suboptimal ... maybe we apply
> the following patch:

The problem isn't (just) the prints, which have always been there, but
when we do the scanning.  I suspect this patch accidentally reversed a
U-Boot local change to defer bad block scanning to first use.

-Scott

  reply	other threads:[~2012-02-13 17:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-13  8:18 [U-Boot] nand: current mainline show "new" startup output Heiko Schocher
2012-02-13 17:06 ` Scott Wood [this message]
2012-02-14  6:38   ` Heiko Schocher
2012-02-14 17:12     ` Scott Wood

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F394302.30504@freescale.com \
    --to=scottwood@freescale.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.