]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/ext3/super.c
ext3: wait on all pending commits in ext3_sync_fs
[linux-2.6-omap-h63xx.git] / fs / ext3 / super.c
index e5717a4fae67740459104b9da4ba8b1f6a79a4ef..5dec6d1356c4b07477bb40f68305c0d9de89258b 100644 (file)
@@ -2390,13 +2390,12 @@ static void ext3_write_super (struct super_block * sb)
 
 static int ext3_sync_fs(struct super_block *sb, int wait)
 {
-       tid_t target;
-
        sb->s_dirt = 0;
-       if (journal_start_commit(EXT3_SB(sb)->s_journal, &target)) {
-               if (wait)
-                       log_wait_commit(EXT3_SB(sb)->s_journal, target);
-       }
+       if (wait)
+               ext3_force_commit(sb);
+       else
+               journal_start_commit(EXT3_SB(sb)->s_journal, NULL);
+
        return 0;
 }