RE: [U-Boot-Users] Booting kernel with initrd

Seems to be misunderstood.
I dont want to create the root filesystem on FAT. I want to have it like the configuration with loadlin, where you have the four files on the FAT filesystem, the kernel, the initrd image, the root filesystem image (ext2) and a swap image. When the kernel boots the initrd, this mounts the root filesystem through the loopback device (root=/dev/loop0), this is described various times on the net.
I have read the manuals about uboot i have found (DLUG).
The bootm command describes how the images (kernel and initrd) are processed, when they are in flash and copied out in memeory. But that not what i need in this case. They must be loaded from filesystem into RAM. It makes no sense to load the images into RAM with another command and then run bootm, which copies them from one position in RAM to another.
The reply from fumin showed a way to do this. Looking at the kernel source for the parameter parsing for initrd parameter assumes initrd=0x00800000,16M to be correct (first start address and then size). I dont understood your reply.
u can load image to 0x00800000 and type command to set bootargs like below: setenv bootargs root=/dev/ram0 mem=128M initrd=0x00800000,16M
This is only needed for broken (Linux) ports. Normally U-Boot will directly pass the ramdisk address top the Linux kernel.
Maybe i have completly misunderstood something, but for me the boot sequency is to load the kernel from filesystem (probable fatload, but where is the documentation for that command), then the initrd, and then starting the kernel with go with bootargs set to root=/dev/loop0 initrd=start,size.
Is this wrong ? Should i use other commands ? Should i use another way to get the kernel and initrd from FAT filesystem ?
Regards, Rainer

Dear Rainer,
in message 2574043332486841A5B27A5FE9769E45014F82C2@esealnt888.al.sw.ericsson.se you wrote:
I want to have it like the configuration with loadlin, where you have the four files on the FAT filesystem, the kernel, the initrd image, the root filesystem image (ext2) and a swap image. When the kernel boots the initrd, this mounts the root filesyste m through the loopback device (root=/dev/loop0), this is described various times on the net.
Can you please restrict your line length to the usual 70 or so characters? Thanks.
I have read the manuals about uboot i have found (DLUG).
The bootm command describes how the images (kernel and initrd) are processed, when they are in flash and copied out in memeory. But that not what i need in this case. They must be loaded from filesystem into RAM. It makes no sense to load the images int
Just use "fatload" to load the images to RAM, then.
o RAM with another command and then run bootm, which copies them from one position in RAM to another.
But this is the way it needs to be done. There is a command to load it to memory (fatload in your case), and another command to uncompress the kernel and start it (bootm).
The reply from fumin showed a way to do this. Looking at the kernel source for the parameter parsing for initrd parameter assumes initrd=0x00800000,16M to be correct (first start address and then size). I dont understood your reply.
I don;t understand your question and/or problem.
Maybe i have completly misunderstood something, but for me the boot sequency is to load the kernel from filesystem (probable fatload, but where is the documentation for that command), then the initrd, and then starting the kernel with go with bootargs s et to root=/dev/loop0 initrd=start,size.
Did you ever try typing "help fatload" at the U-Boot prompt?
Ther eyou got your documentation. If this is not sufficient for you, then please RTFS.
Is this wrong ?
Yes, this is worng. A kernel does NOT get started by "go", but only by "bootm".
Should i use other commands ?
Yes, see above.
Best regards,
Wolfgang Denk
participants (2)
-
Rainer Brestan (VI/SEA)
-
Wolfgang Denk