Resend without code to get around list limit.
Code at
http://users.actrix.co.nz/manningc/yaffs/yaffs_fs-fsx-wip.c
On Monday 30 November 2009 15:01:33 JiSheng Zhang wrote:
> Hi Charles,
>
> > The article is all about new kernel mods and race conditions. The problem
> > of yaffs not running fsx predates these changes.
> >
> > Unfortunately the kernel VFS interface is one of the most changing
> > interfaces in the whole kernel and it is really challenging to keep up.
> > Each file system handles the interface in slightly different ways. What
> > would be nice is simplified fs interfacing layer.
>
> Any progressing on this issue? IMHO, there maybe something wrong with
> yaffs_writepage. If partial write, we should zero the remaining parts
> of the page. But unfortunately the problem isn't fixed after doing so.
>
I have had more of a look at this and have made some progress, but it isn't
right yet.
the failure seems to happen in at least two ways:
* Data wrong from an offset of 0 in a page. Not yet fixed.
* Data wrong in the last part of a page. This seems to have fixed by some of
the zero_user_segment() calls.
I somewhat suspect that the problem is related to page flags not being set
correctly and perhaps there being a missing function (launder_page or
similar).
Attached is some work in progress code. This might not compile in a box
standard yaffs2 due to some unrelated changes.
For testing I have been running tests on a nandsim to get better speed and not
trash real flash. As follows:
$sudo -s
# linux-tests/initnandsim
# insmod yaffs2.ko
# mount -t yaffs2 /dev/mtdblock0 /mnt
# echo +os > /proc/yaffs
# cd /mnt
run fsx
-- Charles