[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
JFFS2 list_dirty corruption
While hacking on JFFS2 for NAND I found a possibility, where scan_medium
corrupts list_dirty.
jffs2_scan_medium calls
jffs2_scan_eraseblock calls
jffs2_scan_dirent_node calls
jffs2_add_fd_to_list
There is a duplicate entry detected, so it calls
jffs2_mark_node_obsolete
There is it possible that the jeb is added to list_dirty,
because it's a duplicate entry
with list_add_tail
We come back to
jffs2_scan_eraseblock
There is another condition, that marks the block dirty
We come back to
jffs2_scan_medium
There we add the block to list_dirty too with add_list
Then we have a circular list entry.
Result: chaos
That's not a problem of the NAND modifications. I verified, that this can
happen in the actual CVS-version too.
--
Thomas
__________________________________________________
Thomas Gleixner, autronix automation GmbH
auf dem berg 3, d-88690 uhldingen-muehlhofen
fon: +49 7556 919891 , fax: +49 7556 919886
mail: gleixner@xxxxxxx.de">http://www.autronix.de
To unsubscribe from this list: send the line "unsubscribe jffs-dev" in
the body of a message to majordomo@xxxxxxx.com