Commit:     44b998e1eb254edc87177819ee693690fac68b7f
Parent:     566865a2a4791c9290155f651ee0c2c606db0b1d
Author:     David Woodhouse <[EMAIL PROTECTED]>
AuthorDate: Mon Apr 23 12:11:46 2007 +0100
Committer:  David Woodhouse <[EMAIL PROTECTED]>
CommitDate: Mon Apr 23 12:11:46 2007 +0100

    [JFFS2] Improve failure mode if inode checking leaves unchecked space.
    We should never find the unchecked size is non-zero after we've finished
    checking all inodes. If it happens, used to BUG(), leaving the alloc_sem
    held and deadlocking. Instead, just return -ENOSPC after complaining. The
    GC thread will die, but read-only operation should be able to continue and
    the file system should be unmountable.
    Signed-off-by: David Woodhouse <[EMAIL PROTECTED]>
 fs/jffs2/gc.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/fs/jffs2/gc.c b/fs/jffs2/gc.c
index 3a3cf22..e92cf0f 100644
--- a/fs/jffs2/gc.c
+++ b/fs/jffs2/gc.c
@@ -144,7 +144,8 @@ int jffs2_garbage_collect_pass(struct jffs2_sb_info *c)
-                       BUG();
+                       up(&c->alloc_sem);
+                       return -ENOSPC;
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at

Reply via email to