UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Newbie rogerstokes
Newbie
5,599 Views
Registered: ‎12-04-2013

Cannot mount Zynq release 14.7 to modify ramdisk

Jump to solution

I unpacked Zynq Release 14.7 into a CentOS 6.4 Virtualbox VM as follows:

 

        bash# tar xvJf 14.7-release.tar.xv

 

then removed the U-boot header from uramdisk.image.gz using:

 

        bash# dd if=uramdisk.image.gz bs=64 skip=1 of=ramdisk.image.gz

 

unzipping the ramdisk and attempting to mount it fails:

 

        bash# gunzip ramdisk.image.gz

        bash# sudo mount –o loop ramdisk.image.gz /mnt/ramdisk

        mount: you must specify the filesystem type

        bash# sudo mount –o loop –t vfat ramdisk.image.gz /mnt/ramdisk

        mount: wrong fs type, bad option, bad superblock on /dev/loop1,

               missing codepage or helper program, or other error

 

so to try and determine why I re-added the header using:

 

        bash# mkimage –A arm –T ramdisk –C gzip –d ramdisk.image.gz uramdisk2.image.gz

 

then did a file compare:

 

        bash# xxd uramdisk.image.gz > u1.hex

        bash# xxd uramdisk2.image.gz > u2.hex

        bash# diff u1.hex u2.hex

        lcl

         < 00000000:  2705 1956 803a b958 5268 139e 0045 89c9  ‘..V.:.XRh...E..

        ---

        > 00000000:  2705 1956 98c7 1b07 529f e79b 0045 89c9  ‘..V....R....E..

 

So perhaps dd modified the start of the unwrapped ramdisk, or the ramdisk itself was corrupted in some way prior to packaging release 14.7 at Xilinx, but it does not affect the operation of U-Boot, while mount detects the error.

 

The above does seem to conform to the U-Boot manual at http://www.denx.de/wiki/DULG/HowToAddFiles so any help or insights as to what the problem is (or a copy of the ramdisk prior to adding the U-Boot header) would be appreciated.

0 Kudos
1 Solution

Accepted Solutions
Xilinx Employee
Xilinx Employee
7,378 Views
Registered: ‎03-13-2012

Re: Cannot mount Zynq release 14.7 to modify ramdisk

Jump to solution

Since a few releases the ramdisk is no longer an initrd but an initramfs. I.e. you cannot mount the image but you can unpack it with cpio.

cpio -i < ramdisk.image

 Furthermore, you could check with the 'file' tool what filetype you are actually dealing with.

View solution in original post

0 Kudos
4 Replies
Xilinx Employee
Xilinx Employee
7,379 Views
Registered: ‎03-13-2012

Re: Cannot mount Zynq release 14.7 to modify ramdisk

Jump to solution

Since a few releases the ramdisk is no longer an initrd but an initramfs. I.e. you cannot mount the image but you can unpack it with cpio.

cpio -i < ramdisk.image

 Furthermore, you could check with the 'file' tool what filetype you are actually dealing with.

View solution in original post

0 Kudos
Newbie rogerstokes
Newbie
5,574 Views
Registered: ‎12-04-2013

Re: Cannot mount Zynq release 14.7 to modify ramdisk

Jump to solution

Thanks for the reply, especially the hint on "file". I note the wiki page "Build and Modify a Rootfs" refers to Zynq ramdisks as initrd.

0 Kudos
Xilinx Employee
Xilinx Employee
5,567 Views
Registered: ‎03-13-2012

Re: Cannot mount Zynq release 14.7 to modify ramdisk

Jump to solution

Yeah, it's a wiki. At the time that page was written it was up to date, but things change. Edits welcome ;)

0 Kudos
3,132 Views
Registered: ‎05-15-2015

Re: Cannot mount Zynq release 14.7 to modify ramdisk

Jump to solution

Hi,

 I am also facing the same issue.

WOuld you please provide me the detail steps on how to add files to ramdisk as I am new to this.

 

Thanks...

0 Kudos