[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Loading emdebian file system on ARM target from USB stick



On Tue, 2009-04-21 at 11:38 -0300, Amandeep Bhullar wrote:
> Hi
> 
> I am reading instructions for installing emdebian at
> http://www.emdebian.org/release/crush/c229.html
> I am not clear about a few things. Please help.
> 
> I have the emdebian filesystem  tarball emdebian-arm.tgz and linux
> kernel uImage for ARM.
> On my target ARM board i am running U-boot 2009.03 and that recognizes
> my USB stick (1GB formatted FAT) and has the files uImage and
> emdebian-arm.tgz
> --------------------------
> U-Boot> usb start
> (Re)start USB...
> USB:   scanning bus for devices... 2 USB Device(s) found
>        scanning bus for storage devices... 1 Storage Device(s) found
> -------------------------
> Next step is to decompress the tarball, but I am not sure how will I
> do it from U-boot command prompt or it is NOT to be given from U-boot
> command prompt? Where do I give the command tar -xzpf
> emdebian-arm.tgz ? I am confused.
Hello Aman,
uboot itself has by default no tar decompression command. You need to
extract the tarball using your host PC on your USB stick. uImage is the
kernel image itself I suppose, without rootfs?
To boot the kernel together with emdebian rootfs you can set the
bootargs variable in uboot: set bootargs root=/dev/... console=ttyS..

The problem here is that the tarball you created is not a working rootfs
(anybody out there please correct me if I am wrong). The flow requires
to have a running system or at least a boot loader with a chroot
command. 

Here is what I have done:
I had a working system with nfs support on the arm board. I copied the
emdebian-arm.tgz to a folder in the nfs tree so that the arm system
could access it.
Afterwards I used chroot on the target and executed the script
emsecondstage which configures the rootfs. Then I quit the chroot
environment and made a JFFS2 flash image from the configured emdebian
root file system directly on the target (The Kernel needs to be
configured with JFFS2 support). The command is mkfs.jffs2.
The flash was partitioned in several sections, one for the bootloader
uboot, one for the kernel and one for the rootfs.
The jffs image was copied to the rootfs flash section.

After this was done I set the bootargs environment to tell the kernel to
use the jffs2 flash section for the rootfs.

I hope this is not too confusing ;-)




> 
> Thanks again for helping me guys.
> Aman.


Reply to: