JFFS2 atomic write?

Dec 06, 2010 0 Replies

Are file writes using JFFS2 atomic?



For example:



  1. There is a file which has been written to FLASH.
  2. The file is opened, modified and closed. The file may occupy multiple sectors in the FLASH.
  3. While the file is being written, power is lost.

Am I guranteed to either get the complete old file or the complete new file. Or could it be something in between.



It looks like the filesystem metadata is handled atomically, but it's not obvious to me if this extends to the user data as well.



Cheers, Mike


Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required