> -----Original Message-----
> From: yaffs-bounces@lists.aleph1.co.uk
> [mailto:yaffs-bounces@lists.aleph1.co.uk] On Behalf Of Louis JANG
> Sent: Monday, 7 April 2008 5:01 PM
> To: yaffs@lists.aleph1.co.uk
> Subject: [Yaffs] mmap, power-off, and data is lost
>
> The above problem is not happened if I read mmap_test file
> before power-off(I used cat). and it's not happened if I
> unmount before. I also have tested the above problem with
> write api instead of mmap, it was not happened in this case.
>
Have you tried calling msync() and/or fsync()?
I think most filesystems will happily cache the file until they're
forced to write it...
James