From: Roger Quadros <rogerq@kernel.org>
To: Colin Foster <colin.foster@in-advantage.com>
Cc: Michael Trimarchi <michael@amarulasolutions.com>,
Dario Binacchi <dario.binacchi@amarulasolutions.com>,
u-boot@lists.denx.de
Subject: Re: U-Boot OMAP GPMC ECC change
Date: Thu, 18 May 2023 13:55:38 +0300 [thread overview]
Message-ID: <20fbcbd5-056b-407a-c506-c29b4359d669@kernel.org> (raw)
In-Reply-To: <ZGUtiNHRGVASZU+m@colin-ia-desktop>
Hi Colin,
On 17/05/2023 22:39, Colin Foster wrote:
> Hi Roger,
>
> Thanks for the tests. I attached the files and commented in line... but
> at the bottom of this email I have some findings...
>
> On Wed, May 17, 2023 at 04:30:55PM +0300, Roger Quadros wrote:
>> Hi Colin,
>>
>> I just tested this on AM335x EVM which uses BCH8_CODE_HW but 8-bit NAND part.
>> I see that you are using 16-bit NAND.
>>
>> One more difference in u-boot configuration. For me:
>> CONFIG_NAND_OMAP_GPMC_PREFETCH=y
>>
>> Not sure if that matters but let's keep it set for now.
>>
>> For debug can you please apply the patch (at end) to u-boot at commit a95410696d21
>> (before breakage) and run the test.
>>
> All are attached.
>
> However I have some other initial findings:
>
> I swapped in just U-Boot (not the SPL) with your patch, and everything
> seems to work!
>
> The issue of Uncorrectable ECC errors spam came from the SPL. Here's a
> snippet of the boot log with the "ecc" print as well as your patch:
>
Thanks for the tests. Glad to hear issue is narrowed down to SPL.
> U-Boot SPL 2023.04-00029-g26a9ce5314-dirty (May 17 2023 - 12:06:49 -0700)
> OMAP4460-GP ES1.1
> Trying to boot from NAND
> ecc: 2420106
> ecc: ebd922f6
> ecc: 333f844f
> ecc: ab812f72
This is clearly the issue. They should all have been 0.
> omap-elm: uncorrectable ECC errors
> omap-elm: uncorrectable ECC errors
> omap-elm: uncorrectable ECC errors
> omap-elm: uncorrectable ECC errors
> ecc: 2420106
> ecc: ebd922f6
> ecc: 333f844f
> ecc: ab812f72
> omap-elm: uncorrectable ECC errors
> omap-elm: uncorrectable ECC errors
> omap-elm: uncorrectable ECC errors
> omap-elm: uncorrectable ECC errors
Can you please share your spl/u-boot.cfg?
We have a stripped down driver "am335x_spl_bch.c"
that deals with NAND at SPL.
I haven't really looked much at that driver but
it relies on omap_gpmc.c for
ecc.hwctl()
read_buf()
ecc.calculate()
We didn't do any functional change to these functions in commit 04fcd25873
unless something slipped through the cracks.
It seems to rely on following config options
CFG_SYS_NAND_ECCPOS
CONFIG_SYS_NAND_PAGE_COUNT
CONFIG_SYS_NAND_PAGE_SIZE
CONFIG_SYS_NAND_5_ADDR_CYCLE
CFG_SYS_NAND_ECCSIZE
CFG_SYS_NAND_ECCBYTES
CONFIG_SYS_NAND_OOBSIZE
Could you please share what they are set to
for your SPL build?
Meanwhile, I'll try to reproduce this on AM335x-EVM.
--
cheers,
-roger
next prev parent reply other threads:[~2023-05-18 10:55 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-09 15:31 U-Boot OMAP GPMC ECC change Colin Foster
2023-05-10 9:42 ` Roger Quadros
2023-05-10 15:38 ` Colin Foster
2023-05-12 11:53 ` Roger Quadros
2023-05-12 16:05 ` Colin Foster
2023-05-13 5:59 ` Roger Quadros
2023-05-17 13:30 ` Roger Quadros
2023-05-17 19:39 ` Colin Foster
2023-05-18 10:55 ` Roger Quadros [this message]
2023-05-18 23:19 ` Colin Foster
2023-05-19 12:41 ` Roger Quadros
2023-05-20 17:27 ` Colin Foster
2023-06-26 5:03 ` Michael Nazzareno Trimarchi
2023-06-27 5:42 ` Colin Foster
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=20fbcbd5-056b-407a-c506-c29b4359d669@kernel.org \
--to=rogerq@kernel.org \
--cc=colin.foster@in-advantage.com \
--cc=dario.binacchi@amarulasolutions.com \
--cc=michael@amarulasolutions.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox