]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
ocfs2: Handle error during journal load
authorWengang Wang <wen.gang.wang@oracle.com>
Tue, 10 Jun 2008 06:24:48 +0000 (14:24 +0800)
committerMark Fasheh <mfasheh@suse.com>
Mon, 14 Jul 2008 20:57:15 +0000 (13:57 -0700)
This patch ensures the mount fails if the fs is unable to load the journal.

Signed-off-by: Wengang Wang <wen.gang.wang@oracle.com>
Acked-by: Sunil Mushran <sunil.mushran@oracle.com>
Signed-off-by: Mark Fasheh <mfasheh@suse.com>
fs/ocfs2/super.c

index df63ba20ae9016d7957930da638b729d9ab242bb..ccecfe5094fa914407d5de8e8292b837a167784f 100644 (file)
@@ -1703,7 +1703,11 @@ static int ocfs2_check_volume(struct ocfs2_super *osb)
        local = ocfs2_mount_local(osb);
 
        /* will play back anything left in the journal. */
-       ocfs2_journal_load(osb->journal, local);
+       status = ocfs2_journal_load(osb->journal, local);
+       if (status < 0) {
+               mlog(ML_ERROR, "ocfs2 journal load failed! %d\n", status);
+               goto finally;
+       }
 
        if (dirty) {
                /* recover my local alloc if we didn't unmount cleanly. */