@@ -32,6 +32,28 @@
* larger is the journal, the more memory its index may consume.
+ * Problem description: unstable pages after unclean power cut on NAND flashes.
+ * If a power cut happens when we have ongoing NAND page program, this page
+ * becomes unstable. The following situations are possible when we mount this
+ * flash next time and UBIFS reads the page.
+ * o The page may look like it is empty, i.e., it contains only 0xFFs, but
+ * we write data there, the data becomes corrupted. I.e., when the data are
+ * read, we may get a ECC errors. Moreover, the page may be read with no
+ * errors sometimes, with an ECC error next time, with a bit-flip next
+ * time, etc.
+ * o The page may have bit-flip, but when it is read next time, it may have
+ * ECC errors or no errors at all.
+ * o An UBIFS node may have correct CRC, but when it is read next time, it
+ * may have CRC error.
+ * IOW, these unstable pages are disaster. UBIFS has to handle them correctly:
+ * never write to them and never rely on their contents.
+ * TODO: handle this for buds, log, orphan area, and master area.