Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++

uncompressing of romfs.img

Altera_Forum
Honored Contributor II
1,292 Views

hello friend  

i have one prblem-> 

 

i have dump my u-boot ,kernel and filesystem with following data 

 

flash: 0x00000000----0x0020000(2MB) 

sdram: 0x00800000----0x00ffffff(8MB) 

restart address: 0x00000000 

exception address: 0x00800020 

u-boot download address: 0x00000000 

the kernel of uclinux download address: 0x00020000 

the kernel of uclinux load address is 0x00800000 

the kernel of uclinux entry address is 0x00800000 

the filesystem of uclinux download address: 0x00100000 

the filesystem of uclinux load address is 0x00a00000 

the filesystem of uclinux entry address is 0x00a00000 

 

u-boot is 100k 

vmlinux.bin.gz is 450KB 

romfs.bin.gz is 438KB 

 

and 

i use the command to compress the kernel : gzip -9 vmlinux.bin 

 

mkimage -A nios2 -O linux -T kernel -C gzip -a 0x00800000 -e 0x00800000 -n 'Linux Kernel Image' -d vmlinux.bin.gz uImage.img 

 

mkimage -A nios2 -O linux -T filesystem -C gzip -a 0x00c00000 -e 0x00c00000 -n 'romfs EP1C6' -d romfs.bin.gz romfs.img 

 

 

but previously ,when i have load onlt romfs.bin (uncompress)at that time ,i got perfect o/p,but now when i use gzip file then kernel is booting but it is not able to uncompress romfs.img 

 

 

please help me
0 Kudos
4 Replies
Altera_Forum
Honored Contributor II
486 Views

You should not compress romfs. 

And romfs should be write to flash on the romfs partition in the mtd map. 

 

It would be easier if you use initramfs. no more romfs headache.
0 Kudos
Altera_Forum
Honored Contributor II
486 Views

 

--- Quote Start ---  

originally posted by hippo@Jun 30 2006, 06:38 AM 

you should not compress romfs. 

and romfs should be write to flash on the romfs partition in the mtd map. 

 

it would be easier if you use initramfs. no more romfs headache. 

<div align='right'><{post_snapback}> (index.php?act=findpost&pid=16543) 

--- quote end ---  

 

--- Quote End ---  

 

 

 

thanks hippo 

but  

can you tell me how to do initromfs? please
0 Kudos
Altera_Forum
Honored Contributor II
486 Views

Please follow step 1-3 in, we use initramfs to build compressed image, zImage. 

Then you can use nios2 flash programmer or u-boot to program the flash. 

http://nioswiki.jot.com/wikihome/operating...ms/%c2%b5clinux (http://nioswiki.jot.com/wikihome/operatingsystems/%c2%b5clinux)
0 Kudos
Altera_Forum
Honored Contributor II
486 Views

Hi All, 

 

> mkimage -A nios2 -O linux -T filesystem -C gzip -a 0x00c00000 -e 0x00c00000 -n &#39;romfs EP1C6&#39; -d  

> romfs.bin.gz romfs.img 

 

Just a note: passing a ramdisk image to the kernel as a parameter from a bootloader will not work. 

The default kernel image (for Nios II) does not recognize any parameters (e.g. command line, 

bd_t, ramdisk) passed to it from a boot loader. Hopefully, we will address this issue in the kernel 

soon -- then add support in u-boot. 

 

hippo, we should discuss this some time ... as it can affect the bzImage design. 

 

Regards, 

--Scott
0 Kudos
Reply