MTD CVS update: 'mtd/include/linux jffs2_fs_sb.h'

David Woodhouse dwmw2 at infradead.org
Fri Mar 8 10:11:24 EST 2002


Update of /home/cvs/mtd/include/linux
In directory infradead.org:/tmp/cvs-serv9305/include/linux

Modified Files:
	jffs2_fs_sb.h 
Log Message:
	node_free_sem
	-------------

This semaphore is only used by the erase code which frees obsolete
node references and the jffs2_garbage_collect_deletion_dirent()
function. The latter function on NAND flash must read _obsolete_ nodes
to determine whether the 'deletion dirent' under consideration can be
discarded or whether it is still required to show that an inode has
been unlinked. Because reading from the flash may sleep, the
erase_completion_lock cannot be held, so an alternative, more
heavyweight lock was required to prevent the erase code from freeing
the jffs2_raw_node_ref structures in question while the garbage
collection code is looking at them.

Suggestions for alternative solutions to this problem would be welcomed.






More information about the linux-mtd-cvs mailing list