[Yaffs] Corruption in the contents of the file system.

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Joaquim Duran
Date:  
To: yaffs
Subject: [Yaffs] Corruption in the contents of the file system.
Dear all,

We've developing a device based on the LogicPD Torpedo module
(http://www.logicpd.com/products/system-on-modules/dm3730-torpedo-wireless-som/).
We've developed our own main board based on our product requirements.
The device runs linux 3.0, with yaffs file system to store data in
flash memory.

Some time to time, we detect that the contents of the flash memory has
been corrupted. The flash corruption is manifested in two different
ways:

1 - Once uImage and rootfs.yaffs2 have been saved to flash, the device
boots fine and after some time, the application that manages the
device is no longer running. If we try to run it, then the executable
crashes with a segmentation fault or invalid instruction.

2 - After saving the uÏmage and rootfs.yaffs2 files to flash, and the
system is booting for first time, the error is shown:

[ 9.906890] Kernel panic - not syncing: No init found. Try passing
init= option to kernel. See Linux Documentation/init.txt for guidance.
[ 9.919952] [<c00c9dd0>] (unwind_backtrace+0x0/0x138) from
[<c054fa64>] (panic+0x6c/0x1a0)

We've enabled traces in yaffs for write, delete and erase operations.
We check that once the application is running (and it is not saving
data), traces of write and delete operations are printed on console:

[ 1049.781890] yaffs: Writing chunk 211437 tags 4454 451
[ 1049.790313] yaffs: Writing chunk 211438 tags 4454 452
[ 1049.809753] yaffs: Writing chunk 211439 tags 4454 453
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
[ 1051.770324] yaffs: Writing chunk 211440 tags 4454 454
[ 1051.780822] yaffs: Writing chunk 211441 tags 4454 455
[ 1051.794158] yaffs: Writing chunk 211442 tags 4454 456
[ 1051.800262] yaffs: Writing chunk 211443 tags 4494 1
[ 1051.817230] yaffs: yaffs_block_became_dirty block 999 state 8
[ 1051.867919] yaffs: Erased block 999
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
TestWatchdogDriver::rearm
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
TestWatchdogDriver::rearm
Module ECG Device: Exception: Op[ 1071.006561] omap_device:
omap2_mcspi.1: new worst case activate latency 0: 1403808
en device handle - LIBUSB_ERROR_NOT_FOUND
[ 1073.856353] yaffs: Writing chunk 211444 tags 4494 0
[ 1073.862304] yaffs: Writing chunk 211445 tags 4454 457
[ 1073.868774] yaffs: Writing chunk 211446 tags 4454 458
[ 1073.875030] yaffs: Writing chunk 211447 tags 4454 459
[ 1073.881317] yaffs: Writing chunk 211448 tags 4454 460
Module ECG Device: Exception: Open device handle - LIBUSB_ERROR_NOT_FOUND
[ 1075.864044] yaffs: Writing chunk 211449 tags 4454 461

NOTE: "Module ECG Device: Exception: Open device handle -
LIBUSB_ERROR_NOT_FOUND" are traces from device application.

but if I check which file has been updated, then no file is shown:

DM-37x# find / -xdev -type f -mmin -5
DM-37x# find / -xdev -type f -mmin -5
DM-37x# find / -xdev -type f -mmin -5

Does these flash operations corresponds to refresh operation? How can
I get the name of the file that yaffs is updating?

Thanks and Best Regards,
Joaquim Duran