public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Nicholas Kinar <n.kinar@usask.ca>
To: u-boot@lists.denx.de
Subject: [U-Boot] Booting kernel from NAND flash on AT91SAM9 custom board using fsload
Date: Sun, 03 Apr 2011 19:25:54 -0600	[thread overview]
Message-ID: <4D991E22.1090807@usask.ca> (raw)
In-Reply-To: <4D97D257.6080502@usask.ca>

Nicholas Kinar wrote:
>
> I now strongly believe that the bootargs are not being passed in
> properly to the kernel.  Having found a posting on the AT91 website [1],
> I now realize that the Linux kernel has been built with a load address
> of 0x20008000, but must be loaded to different address 0x20080000.
>
> Posting:
> [1]
> http://www.at91.com/forum/viewtopic.php/f,12/t,5038/start,0/st,0/sk,t/sd,a/
>
> Now the kernel boots, but as shown below a kernel panic occurs, so I
> think that the issue might be due to the "root=ubi0:container" bootarg.
> How would I set the root bootarg for this particular NAND flash filesystem?
>

Yes, this was exactly the issue; the environment variables were not 
getting passed in properly to the kernel.  Here are the environment 
variables that I used to successfully boot the Linux kernel:

bootargs=noinitrd console=ttyS0,115200 ubi.mtd=1 root=ubi0:rootfs 
mtdparts=flash:10M(kernel),100M(root),-(storage) rw rootfstype=ubifs
nand-boot=ubi part kernel; ubifsmount kernelfs; ubifsload 0x20080000 
uImage; bootm 0x20080000
bootcmd=run nand-boot

Note that on my setup,  "root=ubi0:rootfs", where "rootfs" is the name 
of the volume on the UBI  "root" partition, which is indicated by 
"ubi.mtd=1".  The UBI device being used in the system is "ubi0".  I've 
also checked to see if support for UBIFS and UBI are compiled into the 
kernel (and not loaded as a module).  I had to pass "noinitrd" to ensure 
that the kernel detected the UBI file system on the flash.  In addition, 
as shown in a U-Boot tutorial 
(http://free-electrons.com/doc/u-boot.pdf), I was able to use a nice 
script (nand-boot) that runs from the bootcmd.

So thank you very much to those on this mailing list who helped me to 
get started with this!

Nicholas

  reply	other threads:[~2011-04-04  1:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-29 16:14 [U-Boot] Booting kernel from NAND flash on AT91SAM9 custom board using fsload Nicholas Kinar
2011-03-29 17:37 ` Nicholas Kinar
2011-03-29 17:56   ` Scott Wood
2011-03-29 20:35     ` Nicholas Kinar
2011-03-29 20:46       ` Scott Wood
2011-03-29 20:57         ` Nicholas Kinar
2011-03-29 21:05       ` Wolfgang Denk
2011-03-29 21:46         ` Nicholas Kinar
2011-03-29 21:51           ` Wolfgang Denk
2011-04-02 17:38             ` Nicholas Kinar
2011-04-03  1:50               ` Nicholas Kinar
2011-04-04  1:25                 ` Nicholas Kinar [this message]
2011-03-30  7:17         ` Joakim Tjernlund
2011-03-30  8:54           ` Wolfgang Denk

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=4D991E22.1090807@usask.ca \
    --to=n.kinar@usask.ca \
    --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