[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-arm-kernel
Subject:    Strange problem on PXA270 when try mount jffs2 rootfs mtd partition
From:       "tao yuan" <yuantao99 () gmail ! com>
Date:       2006-02-23 5:33:25
Message-ID: d734aa4a0602222133i7ac12601kb5cf403c3176f75c () mail ! gmail ! com
[Download RAW message or body]

I send the mail before but seems failed so send again.   Sorry if you get
two copies.

Hi all,


I am working with linux2.6.9 and a PXA270 based platform, with Intel J3
Flash as the boot rom (2x16 to compose 32 bit bus width) and I am using blob
as the boot loader.  Blob can tftp and write JFFS2 image to the correct
place(0x240000 - 0x1240000, 16M jffs2 try to act as root file system) since
I had enabled md5chk command and I had verified md5 checksum of the JFFS2
image written in Flash, it's equal to the jffs2 file I generated with "
mkfs.jffs2 -r ./rootfs -o 16m.jffs2 -e 0x40000 --pad=0x1000000".    dump
command of blob also can show expected thing on the place.

During kernel boots up it can detect Flash by CFI and know it support
Intel's extend feature and know it 2x16 32 bits width.  The strange thing
is, I can't mount JFFS2 partition, it always report:
jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0xxxxxxxxx:
0x0fd7 instead
jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0xxxxxxxxx:
0x6614 instead
.....
Cowardly refusing to erase blocks on filesystem with no valid JFFS2 nodes
and then kernel panic b/c without root filesystem.

(Sorry I forget the 0xxxxxxxxx address so I just mark here with xxxx.)

I googled and find this is due to JFFS2 image was not there but I am pretty
that JFFS2 image was correctly written into the Flash.

I am using following information in ./.config


CONFIG_CMDLINE="root=/dev/mtdblock2 rootfstype=jffs2 ip=192.168.1.101:192
.168.1.100::255.255.255.0::eth0:on console=ttyS0,115200 mem=64M"


CONFIG_MTD=y
CONFIG_MTD_PARTITIONS=y
CONFIG_MTD_REDBOOT_PARTS=y
CONFIG_MTD_CHAR=y
CONFIG_MTD_BLOCK=y
CONFIG_MTD_CFI=y
CONFIG_MTD_GEN_PROBE=y
CONFIG_MTD_CFI_ADV_OPTIONS=y
CONFIG_MTD_CFI_NOSWAP=y
CONFIG_MTD_CFI_GEOMETRY=y
CONFIG_MTD_MAP_BANK_WIDTH_1=y
CONFIG_MTD_MAP_BANK_WIDTH_2=y
CONFIG_MTD_MAP_BANK_WIDTH_4=y
CONFIG_MTD_CFI_I2=y
CONFIG_MTD_CFI_INTELEXT=y
CONFIG_MTD_CFI_UTIL=y
CONFIG_MTD_PANTHER=y


and my partition of Flash was:


#define WINDOW_SIZE     32*1024*1024

static struct map_info pxa27x_map = {
    .size =     WINDOW_SIZE,
    .phys =     0x00000000,
    .inval_cache =  pxa27x_map_inval_cache,
};

static struct mtd_partition pxa27x_partitions[] = {
    {
        .name =     "Bootloader",
        .size =     0x00040000,
        .offset =   0,
        .mask_flags =   MTD_WRITEABLE  /* force read-only */
    },{
        .name =     "Kernel",
        .size =     0x00200000,
        .offset =   0x00040000,
    },{
        .name =     "Filesystem",
        .size =     0x01000000,
        .offset =   0x00240000
    }
};


Since failed to use JFFS2 as root filesystem I tried to use NFS as root
filesystem. After boot the system up I tried to "hexdump /dev/mtdblock0" to
try to show something where blob was located, but displaied context is
always 0, which is not the case since blob is there and functional.


Can anybody here give me some points that why this will happen?

Thanks a lot,

Tao
-------------------------------------------------------------------
List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm-kernel
FAQ:        http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette:  http://www.arm.linux.org.uk/mailinglists/etiquette.php

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic