mtd/fs/jffs3 nodemgmt.c,3.9,3.10

Artem Bityuckiy dedekind at infradead.org
Mon Jan 3 13:48:39 EST 2005


Update of /home/cvs/mtd/fs/jffs3
In directory phoenix.infradead.org:/tmp/cvs-serv21119

Modified Files:
	nodemgmt.c 
Log Message:
Slab corruption bugfix:
It is bug to free ic here. The f-> is still exist and points to this ic.
So if we free ic here, we should set f->inocache = NULL too. But it is
easier just not to free ic here - when the correspondent block will be
erased, ic will be freed.
Surely the same should be fixed for JFFS2.


Index: nodemgmt.c
===================================================================
RCS file: /home/cvs/mtd/fs/jffs3/nodemgmt.c,v
retrieving revision 3.9
retrieving revision 3.10
diff -u -r3.9 -r3.10
--- nodemgmt.c	3 Jan 2005 18:43:38 -0000	3.9
+++ nodemgmt.c	3 Jan 2005 18:48:36 -0000	3.10
@@ -696,12 +696,6 @@
 		*p = ref->next_in_ino;
 		ref->next_in_ino = NULL;
 
-		if (ic->nodes == (void *)ic) {
-			DBG_NR(1, "inocache for ino #%u is all gone now. Freeing\n", ic->ino);
-			jffs3_del_ino_cache(c, ic);
-			jffs3_free_inode_cache(ic);
-		}
-
 		spin_unlock(&c->erase_completion_lock);
 	}
 





More information about the linux-mtd-cvs mailing list