[U-Boot] What shall u-boot do before passing 'root=/dev/ram0' to kernel?

Wolfgang Denk wd at denx.de
Thu Dec 18 22:53:01 CET 2008


Dear "mike xu",

In message <7103aeea0812181017j19966d84y22528f8728d5a1c at mail.gmail.com> you wrote:
> 
> Do you know that what u-boot shall do after passing 'root=/dev/ram0'
> to kernel? How kernel locates /dev/ram0?

U-Boot starts the Linux kernel.

How the Linux  kernel  receives  it's  parameters  is  more  a  Linux
specific  question  -  so  far, MIPS failed to com up with a standard
solution for this problem (at least I don't know one).

You might even go ahead and make yourselkf a name in the community by
implementing device tree awarenes for MIPS ;-)

> I want to use one ramdisk as my rootfs, but the kernel failed to mount
> the ramdisk, I set the u-boot parameter as below.
>  setenv bootargs console=ttyS0,115200 root=/dev/ram0 ro mem=128M
> 
> kernel reports errors:
>   No filesystem could mount root, tried:  ext2 cramfs squashfs romfs
>   Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(1,0)

See previous message.

> root=/dev/ram1 also failed... What's the difference between /dev/ram0
> and /dev/ram1?

It's the same as between /dev/sda and /dev/sdb - they are differend
devices.

> And are there any requirement for the ramdisk image? Such as
> little/big endian, block size?

Yes, of course there are such requirements - they have to match what
your kernel expects.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
A woman should have compassion.
	-- Kirk, "Catspaw", stardate 3018.2


More information about the U-Boot mailing list