[Yaffs] why file size changed? yaffs2 used on 512B page NAND…

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Tiger Yin
Date:  
To: yaffs
Subject: [Yaffs] why file size changed? yaffs2 used on 512B page NAND flash.
hi,
I'm porting 2.6.22 kernel to my s3c2410boards, which has 64M NAND
flash (K9F1208). I used yaffs2, downloaded the package and rebuild it
without error.

i added mount command in boot script:
mount -t yaffs /dev/mtdblock4 /etc
mount -t yaffs /dev/mtdblock5 /usr
...

Then reboot system, i found:

yaffs: dev is 32505860 name is "mtdblock4"
yaffs: passed flags ""
yaffs: Attempting MTD mount on 31.4, "mtdblock4"
yaffs: dev is 32505861 name is "mtdblock5"
yaffs: passed flags ""
yaffs: Attempting MTD mount on 31.5, "mtdblock5"
yaffs: dev is 32505862 name is "mtdblock6"
yaffs: passed flags ""
yaffs: Attempting MTD mount on 31.6, "mtdblock6"

it seemed the three partition is mounted ok. then on command line, i
copied some file from USB disk to the partitions, after that i checked
the files, it looked no problem with right file size.
But after i reboot the system, a strange thing happened! all the files
in these partations changed their size to 1024*N ! so lots of them was
truncated and could not be used.
Why the file size changed?! anybody got this issue too?