YAFFS

[1] YAFFS takes advantage of this: dirty pages are marked by writing to a specific spare area byte.

It was based on the YAFFS1 source code, with the major difference being that internal structures are not fixed to assume 512 byte sizing, and a block sequence number is placed on each written page.

YAFFS is a robust log-structured file system that holds data integrity as a high priority.

A variant 'YAFFS/Direct' is used in situations where there is no OS, embedded OSes or bootloaders: it has the same core filesystem but simpler interfacing to both the higher and lower level code and the NAND flash hardware.

YAFFS is locked on a per-partition basis at a high level, allowing only one thread to write at any given time.

When a YAFFS system mounts a NAND flash device, it must visit each block to check for valid data by scanning its spare area.

The main difference is that YAFFS2 needs to jump through significant hoops to meet the "write once" requirement of modern NAND flash.

Thereby when YAFFS2 scans the flash and detects multiple chunks that have identical ObjectIDs and ChunkNumbers, it can choose which to use by taking the greatest sequence number.

For example, when a file is resized to a smaller size, YAFFS1 will mark all of the affected chunks as dirty – YAFFS2 cannot do this due to the "write once" rule.