Hi,
My hardware custom borad is designed based on omapevm board. The linux kernel is 2.6.37,root filesystem is ubifs. Most of time, the linux run well.
But,sometimes, when I finish updating some files(actually is my application files) of rootfs via TFTP or FTP, then read or execute the application file,the error occurred.
Error message are :
....
[ 339.860931] UBIFS error (pid 2081): ubifs_check_node: bad CRC: calculated 0xa28267cf, read 0xe441ca4c
[ 339.870697] UBIFS error (pid 2081): ubifs_check_node: bad node at LEB 252:38912
[ 339.878387] UBIFS error (pid 2081): ubifs_read_node: expected node type 1
[ 339.885498] UBIFS error (pid 2081): do_readpage: cannot read page 132 of inode 2265, error -117
[ 339.962158] UBIFS error (pid 2085): ubifs_check_node: bad CRC: calculated 0xa28267cf, read 0xe441ca4c
[ 339.971923] UBIFS error (pid 2085): ubifs_check_node: bad node at LEB 252:38912
[ 339.979583] UBIFS error (pid 2085): ubifs_read_node: expected node type 1
[ 339.986724] UBIFS error (pid 2085): do_readpage: cannot read page 132 of inode 2265, error -117
...
Are there some bugs in Nand flash MTD driver ?
The steps of creating my root filesystem are:
1./mkfs.ubifs -r /my_dir/ -F -o /my_dir/ubifs.img -m 2048 -e 126976 -c 1002
2../ubinize -o /my_dir/root_ubi.img -m 2048 -p 128KiB -s 512 -O 2048 ubinize.cfg
Content of ubinize.cfg file is:
[ubifs]
mode=ubi
image=/my_dir/ubifs.img
vol_id=0
vol_size=121MiB
vol_type=dynamic
vol_name=rootfs
vol_flags=autoresize
I get my root filesystem MTD partition info via mtdinfo tool,the info is :
mtd5
Name: Root Filesystem
Type: nand
Eraseblock size: 131072 bytes, 128.0 KiB
Amount of eraseblocks: 1024 (134217728 bytes, 128.0 MiB)
Minimum input/output unit size: 2048 bytes
Sub-page size: 512 bytes
OOB size: 64 bytes
Character device major/minor: 90:10
Bad blocks are allowed: true
Device is writable: true
The steps of flashing my root filesystem are:
in u-boot stage using nand flash command,
u-boot# nand erase 0x780000 0xF880000
u-boot# nand write 0x82000000 0x780000 0xFC0000