All of lore.kernel.org
 help / color / mirror / Atom feed
From: Willy Tarreau <w@1wt.eu>
To: Justin Mitchell <jmitchell@aes-corp.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: NAND Flash Issue Need Help!
Date: Fri, 5 Mar 2021 20:36:05 +0100	[thread overview]
Message-ID: <20210305193605.GB31072@1wt.eu> (raw)
In-Reply-To: <MN2PR04MB5615A581CF6938C780531C7F95969@MN2PR04MB5615.namprd04.prod.outlook.com>

Hello,

On Fri, Mar 05, 2021 at 06:38:08PM +0000, Justin Mitchell wrote:
> Issue:
> Intermittent occurrence of failure to program new boards from CM.

No idea what "CM" is here, but that's not relevant here anyway.

> Primary partition mounted OK
> Loading file 'dtb/at91sam9g25ek.dtb' to addr 0x21000000 with size 25836 (0x000064ec)...
> Done
> DTB file loaded OK
> Loading file 'kernel/uImage' to addr 0x22000000 with size 2968536 (0x002d4bd8)...
> UBIFS error (pid 0): ubifs_read_node: bad node type (255 but expected 1) UBIFS error (pid 0): ubifs_read_node: bad node at LEB 215:0 UBIFS error (pid 0): do_readpage: cannot read page 178 of inode 1244, error -22 Error reading file 'kernel/uImage'
> kernel/uImage not found!

But this is not a Linux issue if its U-boot which is failing to load the
kernel. Are you sure you didn't upgrade u-boot at the same time as your
kernel ?

> If I will do ubifscat kernel/uImage it starts to read the file and then I see this error:
> 
> P?@ ???P?@ ???P?@ ??Q?? ?
(...)
> -- System haltedAttempting division by 0!stack-protector: Kernel stack is corrupted Uncompressing Linux...decompressor returned an error done, booting the kernel.
(...)

That's not an error :-)  It's the contents of the bootstrap code in the
kernel that deals with very early issues such as decompression failures.
You're just dumping your kernel image to the screen here.

(...)
> ubifsmount <volume-name>
>     - mount 'volume-name' volume
> 
> And if I will do the same second time then it starts but getting no uImage error:
> 
> DTB file loaded OK
> Loading file 'kernel/uImage' to addr 0x22000000 with size 2968536 (0x002d4bd8)...
> UBIFS error (pid 0): ubifs_read_node: bad node type (255 but expected 1) UBIFS error (pid 0): ubifs_read_node: bad node at LEB 215:0 UBIFS error (pid 0): do_readpage: cannot read page 178 of inode 1244, error -22 Error reading file 'kernel/uImage'
> kernel/uImage not found!
> 
> Strange that I need to run same command twice and that uImage also can not be loaded from SystemB

So indeed that has nothing to do with Linux. Maybe your image is much larger
than the previous one and a bug in the u-boot code used to load the image
makes it randomly fail.
 
Hoping this helps,
Willy

  reply	other threads:[~2021-03-05 19:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-05 18:38 NAND Flash Issue Need Help! Justin Mitchell
2021-03-05 19:36 ` Willy Tarreau [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-03-04 19:46 Justin Mitchell

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=20210305193605.GB31072@1wt.eu \
    --to=w@1wt.eu \
    --cc=jmitchell@aes-corp.com \
    --cc=linux-kernel@vger.kernel.org \
    /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.