2010-03-19 09:47:52     JFFS2 fails to work?

Document created by Aaronwu Employee on Aug 21, 2013
Version 1Show Document
  • View in full screen mode

2010-03-19 09:47:52     JFFS2 fails to work?

Joonas Reunamo (FINLAND)

Message: 87479   

 

Hello,

 

I compiled new Kernel (the latest svn) and wanted to use jffs2 as root file system. Im running on bluetechnix cm-bf537e and followed dvice for installing linux. vmImage to address 0x2004000 and rootfs.jffs2 to 0x20140000 and setting additional "root/dev/mtdblock2 rootfstype=jffs2" to the bootargs in u-boot.

 

Linux boots ok but jffs2 has problems

 

JFFS2 warning: (153) jffs2_do_read_inode_internal: Truncating ino #221 to 1058708 bytes failed because it only had 932742 bytes to start with!                                   

sh: can't open '/dev/null': No space left on device                                                                                                                              

sh: can't open '/dev/null': No space left on device 

 

 

 

Below all startup:

 

Any ideas what goes wrong?

 

 

 

 

 

 

 

## Booting kernel from Legacy Image at 01000000 ...                                                                                                                              

   Image Name:   bf537-2.6.33-ADI-2010R1-pre-svn8                                                                                                                                

   Created:      2010-03-19  12:49:26 UTC                                                                                                                                        

   Image Type:   Blackfin Linux Kernel Image (lzma compressed)                                                                                                                   

   Data Size:    886637 Bytes = 865.9 kB                                                                                                                                         

   Load Address: 00001000                                                                                                                                                        

   Entry Point:  001d3794                                                                                                                                                        

   Verifying Checksum ... OK                                                                                                                                                     

   Uncompressing Kernel Image ... OK                                                                                                                                             

Starting Kernel at = 001d3794                                                                                                                                                    

Linux version 2.6.33-ADI-2010R1-pre-svn8463 (joonas@nuhamasiina) (gcc version 4.1.2 (ADI svn)) #5 Fri Mar 19 14:49:19 EET 2010                                                   

register early platform devices                                                                                                                                                  

bootconsole [early_shadow0] enabled                                                                                                                                              

bootconsole [early_BFuart0] enabled                                                                                                                                              

early printk enabled on early_BFuart0                                                                                                                                            

Board Memory: 32MB                                                                                                                                                               

Kernel Managed Memory: 32MB                                                                                                                                                      

Memory map:                                                                                                                                                                      

  fixedcode = 0x00000400-0x00000490                                                                                                                                              

  text      = 0x00001000-0x0013ce80                                                                                                                                              

  rodata    = 0x0013ce80-0x001a6990                                                                                                                                              

  bss       = 0x001a7000-0x001b6c8c                                                                                                                                              

  data      = 0x001b6c8c-0x001c8000                                                                                                                                              

    stack   = 0x001c6000-0x001c8000                                                                                                                                              

  init      = 0x001c8000-0x001e8000                                                                                                                                              

  available = 0x001e8000-0x01e00000                                                                                                                                              

  DMA Zone  = 0x01e00000-0x02000000                                                                                                                                              

Hardware Trace Active and Enabled                                                                                                                                                

Boot Mode: 0                                                                                                                                                                     

Blackfin support (C) 2004-2009 Analog Devices, Inc.                                                                                                                              

Compiled for ADSP-BF537 Rev 0.3                                                                                                                                                  

Blackfin Linux support by   blackfin.uclinux.org/                                                                                                                           

Processor Speed: 525 MHz core clock and 131 MHz System Clock                                                                                                                     

NOMPU: setting up cplb tables                                                                                                                                                    

Instruction Cache Enabled for CPU0                                                                                                                                               

  External memory: cacheable in instruction cache                                                                                                                                

Data Cache Enabled for CPU0                                                                                                                                                      

  External memory: cacheable (write-back) in data cache                                                                                                                          

Built 1 zonelists in Zone order, mobility grouping off.  Total pages: 7620                                                                                                       

Kernel command line: root=/dev/mtdblock2 rootfstype=jffs2 rw clkin_hz=25000000 earlyprintk=serial,uart0,115200 console=ttyBF0,115200                                             

PID hash table entries: 128 (order: -3, 512 bytes)                                                                                                                               

Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)                                                                                                                    

Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)                                                                                                                      

Memory available: 28480k/32768k RAM, (128k init code, 1263k kernel code, 557k data, 2048k dma, 292k reserved)                                                                    

Hierarchical RCU implementation.                                                                                                                                                 

NR_IRQS:138                                                                                                                                                                      

Configuring Blackfin Priority Driven Interrupts                                                                                                                                  

console [ttyBF0] enabled, bootconsole disabled                                                                                                                                   

console [ttyBF0] enabled, bootconsole disabled                                                                                                                                   

Calibrating delay loop... 1046.52 BogoMIPS (lpj=2093056)                                                                                                                         

Security Framework initialized                                                                                                                                                   

Mount-cache hash table entries: 512                                                                                                                                              

Blackfin Scratchpad data SRAM: 4 KB                                                                                                                                              

Blackfin L1 Data A SRAM: 16 KB (9 KB free)                                                                                                                                       

Blackfin L1 Data B SRAM: 16 KB (16 KB free)                                                                                                                                      

Blackfin L1 Instruction SRAM: 48 KB (37 KB free)                                                                                                                                 

NET: Registered protocol family 16                                                                                                                                               

Blackfin DMA Controller                                                                                                                                                          

cm_bf537e_init(): registering device resources                                                                                                                                   

bio: create slab <bio-0> at 0                                                                                                                                                    

Switching to clocksource jiffies                                                                                                                                                 

NET: Registered protocol family 2                                                                                                                                                

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)                                                                                                                   

TCP established hash table entries: 1024 (order: 1, 8192 bytes)                                                                                                                  

TCP bind hash table entries: 1024 (order: 0, 4096 bytes)                                                                                                                         

TCP: Hash tables configured (established 1024 bind 1024)                                                                                                                         

TCP reno registered                                                                                                                                                              

UDP hash table entries: 256 (order: 0, 4096 bytes)                                                                                                                               

UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)                                                                                                                          

NET: Registered protocol family 1                                                                                                                                                

JFFS2 version 2.2. (NAND) �© 2001-2006 Red Hat, Inc.                                                                                                                             

msgmni has been set to 55                                                                                                                                                        

io scheduler noop registered (default)                                                                                                                                           

io scheduler cfq registered                                                                                                                                                      

bfin_sport: registered sport0                                                                                                                                                    

bfin_sport: registered sport1                                                                                                                                                    

bfin-uart: Blackfin serial driver                                                                                                                                                

bfin-uart.0: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART                                                                                                                 

bfin-uart.1: ttyBF1 at MMIO 0xffc02000 (irq = 20) is a BFIN-UART                                                                                                                 

brd: module loaded                                                                                                                                                               

gpio-addr-flash: probing 16-bit flash bus                                                                                                                                        

gpio-addr-flash: Found 1 x16 devices at 0x0 in 16-bit bank                                                                                                                       

NOR chip too large to fit in mapping. Attempting to cope...                                                                                                                      

Intel/Sharp Extended Query Table at 0x010A                                                                                                                                      

Intel/Sharp Extended Query Table at 0x010A                                                                                                                                      

Intel/Sharp Extended Query Table at 0x010A                                                                                                                                      

Intel/Sharp Extended Query Table at 0x010A                                                                                                                                      

Intel/Sharp Extended Query Table at 0x010A                                                                                                                                      

Using buffer write method                                                                                                                                                        

Using auto-unlock on power-up/resume                                                                                                                                             

cfi_cmdset_0001: Erase suspend on write enabled                                                                                                                                  

Reducing visibility of 8192KiB chip to 4096KiB                                                                                                                                   

RedBoot partition parsing not available                                                                                                                                          

gpio-addr-flash: Using board partition definition                                                                                                                                

Creating 3 MTD partitions on "gpio-addr-flash":                                                                                                                                  

0x000000000000-0x000000040000 : "bootloader(nor)"                                                                                                                                

0x000000040000-0x000000140000 : "linux kernel(nor)"                                                                                                                              

0x000000140000-0x000000400000 : "file system(nor)"                                                                                                                               

bfin-spi bfin-spi.0: chipselect 1 already in use                                                                                                                                 

bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_base@ffc00500, dma channel@7                                                                      

bfin_mii_bus: probed                                                                                                                                                             

arch/blackfin/mach-bf537/boards/cm_bf537e.c:bfin_get_ether_addr: Setting Ethernet MAC to a random one                                                                            

bfin_mac: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=25)@sclk=131MHz)                                                           

bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1                                                                                                           

i2c /dev entries driver                                                                                                                                                          

i2c-bfin-twi i2c-bfin-twi.0: Blackfin BF5xx on-chip I2C TWI Contoller, regs_base@ffc01400                                                                                        

TCP cubic registered                                                                                                                                                             

NET: Registered protocol family 17                                                                                                                                               

VFS: Mounted root (jffs2 filesystem) on device 31:2.                                                                                                                             

Freeing unused kernel memory: 128k freed                                                                                                                                         

dma_alloc_init: dma_page @ 0x001e4000 - 512 pages at 0x01e00000                                                                                                                  

JFFS2 warning: (153) jffs2_do_read_inode_internal: Truncating ino #221 to 1058708 bytes failed because it only had 932742 bytes to start with!                                   

sh: can't open '/dev/null': No space left on device                                                                                                                              

sh: can't open '/dev/null': No space left on device                                                                                                                              

                           _____________________________________                                                                                                                 

        a8888b.           / Welcome to the uClinux distribution \                                                                                                                

       d888888b.         /       _     _                         \                                                                                                               

       8P"YP"Y88        /       | |   |_|            __  __ (TM)  |                                                                                                              

       8|o||o|88  _____/        | |    _ ____  _   _ \ \/ /       |                                                                                                              

       8'    .88       \        | |   | |  _ \| | | | \  /        |                                                                                                              

       8`._.' Y8.       \       | |__ | | | | | |_| | /  \        |                                                                                                              

      d/      `8b.       \      \____||_|_| |_|\____|/_/\_\       |                                                                                                              

     dP   .    Y8b.       \   For embedded processors including   |                                                                                                              

    d8:'  "  `::88b        \    the Analog Devices Blackfin      /                                                                                                               

   d8"         'Y88b        \___________________________________/                                                                                                                

  :8P    '      :888                                                                                                                                                             

   8a.   :     _a88P         For further information, check out:                                                                                                                 

._/"Yaa_:   .| 88P|            -   blackfin.uclinux.org/                                                                                                                   

\    YP"    `| 8P  `.          -   docs.blackfin.uclinux.org/                                                                                                              

/     \.___.d|    .'           -   www.uclinux.org/                                                                                                                        

`--..__)8888P`._.'  jgs/a:f    -   www.analog.com/blackfin                                                                                                                 

                                                                                                                                                                                 

Have a lot of fun...                                                                                                                                                             

                                                                                                                                                                                 

                                                                                                                                                                                 

                            powered by                                                                                                                                           

         ____  _            _            _           _                                                                                                                           

        | __ )| |_   _  ___| |_ ___  ___| |__  _ __ (_)_  __                                                                                                                     

        |  _ \| | | | |/ _ \ __/ _ \/ __| '_ \| '_ \| \ \/ /                                                                                                                     

        | |_) | | |_| |  __/ ||  __/ (__| | | | | | | |>  <                                                                                                                      

        |____/|_|\__,_|\___|\__\___|\___|_| |_|_| |_|_/_/\_\                                                                                                                     

                                                                                                                                                                                 

                        www.bluetechnix.com                                                                                                                                      

                                                                                                                                                                                 

                                                                                                                                                                                 

BusyBox v1.15.3 (2010-03-19 13:38:07 EET) hush - the humble shell                                                                                                                

Enter 'help' for a list of built-in commands.                                                                                                                                    

                                                                                                                                                                                 

root:/>

QuoteReplyEditDelete

 

 

2010-03-19 23:32:17     Re: JFFS2 fails to work?

Yi Li (CHINA)

Message: 87491   

 

Joonas,

 

How do you create and write your jffs2 image to flash? Can you post your steps here?

 

-Yi

QuoteReplyEditDelete

 

 

2010-03-22 06:37:11     Re: JFFS2 fails to work?

Joonas Reunamo (FINLAND)

Message: 87562   

 

I create rootfs.jffs2 with make. I have enabled it with make and other stuff adviced in this projects jffs2 wiki page.

 

It became this time exactly 2mb

 

I load it over tftp

 

tftp 0x1000000 rootfs.jffs2

 

protect off 0x20140000 +$(filesize)

 

erase 0x20140000 +$(filesize)

 

cp.b 0x1000000 0x20140000 $(filesize)

 

cmp.b 0x1000000 0x20140000 $(filesize) gives that only 2 bytes were same but I guess this is because of some memory addressing thing because, as far as I have understood cm-bf537e uses gpio addressing and this address goes above 2mb

 

System boots but show but I cant save stuff

 

Thanks for help!

QuoteReplyEditDelete

 

 

2010-03-24 05:47:43     Re: JFFS2 fails to work?

Yi Li (CHINA)

Message: 87661   

 

Joonas,

 

Can you try 2009R1.1 release on your board?

 

-Yi

QuoteReplyEditDelete

 

 

2010-03-24 07:12:37     Re: JFFS2 fails to work?

Joonas Reunamo (FINLAND)

Message: 87663   

 

I have tried. It didn't function either. Filesystems failed at boot I guess because jffs2 was slightly bigger than 3mb.

 

Joonas

Attachments

    Outcomes