This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
Re: CRC Error when uncompressing image from JFFS2
Well, it is my mistake. When mkfs.jffs2 i should be using the --pad
flag and specify the final padded size of the image and leave the -e as
per the erase block size.
I have tested it out now the image boots fine.
Thanks once again.
Cheers,
Benny
On Thu, 2005-08-25 at 10:13, Benny Chen wrote:
> I must agree that the error is due to corrupted kernel image. However,
> I think the cause of it is due to my erase block size '-e' during
> mkfs.jffs2 stage, I am not sure though.
>
> Below are my observations:
> 1. The same ramdisk.gz and zImage boots fine when downloaded via TFTP.
>
> 2. When I remake the jffs2.image with the erase block size set to my
> flash's actual erase block size (0x20000) it loads and boot fine.
>
> mkfs.jffs2 -d ./jffs2_dir/ -e 0x0020000 -l -p -o ./jffs2.image
>
>
> However, when I run mkfs.jffs2 with a larger erase block size
> (multiples of 0x20000) the loaded images are corrupted.
>
> mkfs.jffs2 -d ./jffs2_dir/ -e 0x0100000 -l -p -o ./jffs2.image
>
> The only reason why I set the erase block size to a larger value is
> because so my apps can write to the jffs2 partitons without having the
> 'run out of space' issue. Unless there is another way of creating a
> JFFS2 partition with additional free blocks to get over the 'run out of
> space' problem.
>
> Any idea?
>
> Regards,
> Benny Chen
>
> On Wed, 2005-08-24 at 17:23, Andrew Lunn wrote:
> > On Wed, Aug 24, 2005 at 11:01:42AM +1000, Benny Chen wrote:
> > > Dear all,
> > > I am not sure if anyone has seen this error. When I tried to run 'exec
> > > -r 0x220000' on images (ramdisk.gz and zImage) loaded from the jffs2
> > > partition in RedBoot I get the following error.
> > >
> > > Both the images works fine when loaded via tftp.
> > >
> > > Any help will be much appreciated.
> > >
> > > Regards,
> > > Benny
> > >
> > >
> > > /********* REDBOOT COMMAND OUTPUT **************/
> > >
> > > RedBoot> ls
> > > directory /
> > > 1 drwxr-xr-x 1 size 0 .
> > > 1 drwxr-xr-x 1 size 0 ..
> > > 3 -rwxr-xr-x 1 size 677528 zImage
> > > 2 -rw-r--r-- 1 size 3496544 ramdisk.gz
> > > RedBoot> load -v -r -b 0x220000 ramdisk.gz
> > > Using default protocol (file)
> > > |
> > > Raw file loaded 0x00220000-0x00575a5f, assumed entry at 0x00220000
> > > RedBoot> load -v -r -b 0x80000 zImage
> > > Using default protocol (file)
> > > -
> > > Raw file loaded 0x00080000-0x00125697, assumed entry at 0x00080000
> > > RedBoot> exec -r 0x220000
> > > Using base address 0x00080000 and length 0x000a5698
> > > Uncompressing Linux..............................................
> > >
> > > crc error
> >
> > Linux itself is printing this error message. This makes me think the
> > zImage is corrupt. I would double check what you have in the JFFS2
> > filesystem is OK.
> >
> > Andrew
>
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss