This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: JFFS2 no space left on device error


On Mon, Aug 01, 2005 at 03:17:48PM +0300, Edgar Grimberg wrote:
> 
> >When you created the image (in RedBoot), did you make it larger
> >than the actual JFFS2 image that you created?  In other words,
> >JFFS2 needs additional FLASH space within the RedBoot (FIS)
> >image in order to create new files (or even rewrite/update
> >existing ones).
> >
> > 
> >
> 
> Hello Gary,
> 
> Thanks for the response. I am describing the exact steps that I 
> followed, maybe this will clear up the problems that I have:
> 
> 1. the ecos.ecc file from my build tree contains:
> 
> cdl_component CYGNUM_IO_FLASH_BLOCK_CFG_STATIC_1 {
>    # Flavor: bool
>    user_value 0
>    # value_source user
>    # Default value: 1
> };
> cdl_component CYGNUM_IO_FLASH_BLOCK_CFG_FIS_1 {
>    # Flavor: bool
>    user_value 1
>    # value_source user
>    # Default value: 0
> };
> # >
> # Name of FIS entry
> #
> cdl_component CYGDAT_IO_FLASH_BLOCK_FIS_NAME_1 {
>    # Flavor: data
>    user_value "\"jffs2\""
>    # value_source user
>    # Default value: "\"jffs2\""
> };

You actually called it JFFS2 in FIS, not jffs2. I'm not sure if this
matters.....
 
> 2. Create the jffs2 image file using:
> 
> mkfs.jffs2 --pad=0x20000 -e 0x10000 -r ./etc -o ./jffs2.img
> 
> 3. Upload the image file to flash, using RedBoot and FIS:
> 
> RedBoot> load -m ymodem -b %{FREEMEMLO} -r
> CRaw file loaded 0x20007000-0x20026fff, assumed entry at 0x20007000
> xyzModem - CRC mode, 1026(SOH)/0(STX)/0(CAN) packets, 5 retries
> RedBoot> fis create -b 0x20007000 -l 0x40000 -s 0x30000 -f 0x10b0000 JFFS2
> ... Erase from 0x010b0000-0x010f0000: ....
> ... Program from 0x20007000-0x20037000 at 0x010b0000: ...
> ... Erase from 0x013f0000-0x01400000: .
> ... Program from 0x20070000-0x20080000 at 0x013f0000: .
> RedBoot> fis list
> Name              FLASH addr  Mem addr    Length      Entry point
> RedBoot           0x01000000  0x01000000  0x00020000  0x00000000
> JFFS2             0x010B0000  0x010B0000  0x00040000  0x20007000
> FIS directory     0x013F0000  0x013F0000  0x0000F000  0x00000000
> RedBoot config    0x013FF000  0x013FF000  0x00001000  0x00000000
> 
> 4. Program the first test for JFFS2 from ecos, using the bdi2000 
> debugger, taking care not to erase the FIS directory or the jffs2 images 
> from flash. The test is programmed at 0x1000000, just over redboot 
> (maybe this is a problem?)

Err, actually yes it could be. To read the FIS directory is calls into
Redboot. If you have stomped over redboot im supprised the test even
runs. Looking at your FIS directory you have 0x01020000 - 0x10AFFFF
free. Try linking jffs2_1 to run at that address and put Redboot back
at 0x01000000.
 
> 5. Run the test (jffs2_1) and get the following:
> 
> <INFO>: reading directory /
> <INFO>: entry              . [mode 016f0001 ino 00000001 nlink 1 size 0]
> <INFO>: entry             .. [mode 016f0001 ino 00000001 nlink 1 size 0]

This does not seem right. There should be other entries. Try 

jffs2dump -content ./jffs2.img

and see if etc, passwd etc is in the image.

        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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]