[meta-xilinx] help with copying rootfs.tar.gz to sd card.

Nathan Rossi nathan.rossi at xilinx.com
Mon Sep 9 19:22:43 PDT 2013


> -----Original Message-----
> From: meta-xilinx-bounces at yoctoproject.org [mailto:meta-xilinx-
> bounces at yoctoproject.org] On Behalf Of Anup Kini
> Sent: Monday, September 09, 2013 11:07 PM
> To: meta-xilinx at yoctoproject.org
> Subject: [meta-xilinx] help with copying rootfs.tar.gz to sd card.
> 
> Hi All,
> 
> I have build a linaro-image-minimal with meta-xilinx for the ZYNQ board.
> On completing the build image process using hob, i have the following
> files.
> 
> 1. hob-image-20130909-135857-zc702-zynq7-20130909120154.rootfs.tar.gz
> 2. hob-image-20130909-135857-zc702-zynq7-20130909120154.rootfs.ext2.gz
> 3. two more images and uImage files.
> 
> Since i need SD boot i should be using the first image, right ?
> Now, i have formatted the SD card to hve 36 MB fat32 and the rest ext4
> partition.
> I looked up the ADI reference to do this part.
> 

Hi Anup,

If you are referring to the guide at http://wiki.analog.com/resources/tools-software/linux-drivers/platforms/zynq then this does not apply for Yocto generated root filesystems (only linaro images).

When writing the root file system to your SD card (or any other device) make sure you have prepared the partition correctly. This means it should be formatted as ext2/3/4.

Mount the partition, extract into it (without the extra parameters of tar you are using). Then un-mount the partition and you are done.

$ sudo mount /dev/... /media/rootfs
$ sudo tar -C /media/rootfs -xzf <image-name>.tar.gz
$ sudo umount /media/rootfs

These instructions are not specific to meta-xilinx, Zynq or Xilinx. So they are the same for other Yocto layers and BSPs.

Also note, the "*.rootfs.ext2.gz" is generally used for ramdisk style boots. You could use it for an SD card image if you wish just 'dd' the ungzipped ext2 block file onto the partition's /dev/ node.

Regards,
Nathan





More information about the meta-xilinx mailing list