]> git.baikalelectronics.ru Git - kernel.git/commit
jffs2: Fix corruption when flash erase/write failure
authorJoakim Tjernlund <Joakim.Tjernlund@transmode.se>
Thu, 28 May 2009 15:43:59 +0000 (17:43 +0200)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Fri, 29 May 2009 09:44:46 +0000 (10:44 +0100)
commit82122442c2e36c9c76c2685a2bcc4a6b4b9cb66a
tree59b7eabd1477825c48278956a9a9a387ee92d12b
parentb33ae0cf0a750ec48491f82a9aedee5b234ca56d
jffs2: Fix corruption when flash erase/write failure

Erase errors such as:
"Newly-erased block contained word 0xa4ef223e at offset 0x0296a014"
and failure to write the clean marker,
moves the offending erase block to erasing list before calling
jffs2_erase_failed(). This is bad as jffs2_erase_failed() will
also move the block to the bad_list, but is now moving the
wrong block, causing FS corruption.

Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
fs/jffs2/erase.c