public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Detlev Zundel <dzu@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] uboot kernel rejects filesystem
Date: Tue, 12 May 2009 11:58:05 +0200	[thread overview]
Message-ID: <m2preelk2a.fsf@ohwell.denx.de> (raw)
In-Reply-To: <a29be8140905120116p1991934eoa9424b6641a068ef@mail.gmail.com> (Bharat Bhushan's message of "Tue, 12 May 2009 13:46:23 +0530")

Hi Bharat,

> I am very new to u-boot.

Welcome aboard!

> I have kernel image, which I loaded to NOR of my board and with bootm,
> control passes to kernel and it starts booting.
> There is panic in kernel: since it can not find the file-system. I am
> afraid, I did make trivial mistake.
>
> I have flashed squashfs filesystem image to NOR @ address NOR1 <I did not
> define any partition>.
> I do not have MTD support.
>
> Now I tried booting like after setting
>
>
> setenv kernel_addr 0xBF060000        <<Note this has u-boot hdr generated
> form mkimage>>
> setenv ramdisk_addr 0xBF260000    <<Note this does not have u-boot hdr
> generated form mkimage>>
> setenv bootargs 'filesystem=squashfs'
> I do bootm ${kernel_addr} ${ramdisk_addr}

This is not correct.  The second argument for bootm is a "real ramdisk"
or "initrd" in Linux speak.  The squashfs filesystem that you use needs
a MTD device and thus can not be passed in this way.

> I do get error from U_BOOT that :
> *Wrong Ramdisk Image Format
> Ramdisk image is corrupt or invalid

That's to be expected, because U-Boot wants the initrd to be wrapped
with mkimage also - which is irrelevant in your case though.

> *I am sure that I have done something wrong in this process:
>
> Few Questions which I could not find the answer:
> 1. Can I nor-flash the image without u-boot hdr.

Sure you can.  You should flash it to the address of a partition defined
inside of the Linux MTD subsystem.

> 2. Is it necessary to have MTD partition defined.

You will of course need to define MTD partitions inside of Linux -
whereas in U-Boot this is optional.

> 3. Do we have any document which specify the boot arguments in context of
> U_BOOT. I tried denx website. I could not figure out much. May be I do not
> what to search for.

What exactly do you mean by "boot arguments"?

> Any help would be highly appreciated.

To solve your problem, do the following:

1. Find out which MTD device (in Linux) you want to use to hold the
   squashfs image.  I'll assume mtd0 below.
2. If you do not want to use partitioning in U-Boot then determine the
   physical address that this device maps to
3. Flash the squasfs image to that address
4. Be sure to include "root=/dev/mtdblock0" on the Linux command line so
   Linux knows where it finds its rootfs.

Cheers
  Detlev

-- 
We support democracy, but that doesn't mean we have to support
governments that get elected as a result of democracy.
                                     -- George W. Bush - March 30, 2006
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de

  reply	other threads:[~2009-05-12  9:58 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-12  8:16 [U-Boot] uboot kernel rejects filesystem Bharat Bhushan
2009-05-12  9:58 ` Detlev Zundel [this message]
     [not found]   ` <a29be8140905120802m2ab0aa83m32b6a7b1194bbb0b@mail.gmail.com>
2009-05-12 15:40     ` Detlev Zundel
2009-05-14 19:45       ` Bharat Bhushan
2009-05-14 20:01         ` Wolfgang Denk
2009-05-15 14:48         ` Detlev Zundel
2009-05-15 18:50           ` Bharat Bhushan
2009-05-15 19:42             ` Detlev Zundel
2009-05-18 13:31               ` Bharat Bhushan
2009-05-19 14:14                 ` Detlev Zundel

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=m2preelk2a.fsf@ohwell.denx.de \
    --to=dzu@denx.de \
    --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