diff options
Diffstat (limited to 'fs/jbd/commit.c')
-rw-r--r-- | fs/jbd/commit.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/fs/jbd/commit.c b/fs/jbd/commit.c index 1b27f46e6108..52c15c776029 100644 --- a/fs/jbd/commit.c +++ b/fs/jbd/commit.c | |||
@@ -309,7 +309,14 @@ void journal_commit_transaction(journal_t *journal) | |||
309 | if (journal->j_flags & JFS_FLUSHED) { | 309 | if (journal->j_flags & JFS_FLUSHED) { |
310 | jbd_debug(3, "super block updated\n"); | 310 | jbd_debug(3, "super block updated\n"); |
311 | mutex_lock(&journal->j_checkpoint_mutex); | 311 | mutex_lock(&journal->j_checkpoint_mutex); |
312 | journal_update_sb_log_tail(journal); | 312 | /* |
313 | * We hold j_checkpoint_mutex so tail cannot change under us. | ||
314 | * We don't need any special data guarantees for writing sb | ||
315 | * since journal is empty and it is ok for write to be | ||
316 | * flushed only with transaction commit. | ||
317 | */ | ||
318 | journal_update_sb_log_tail(journal, journal->j_tail_sequence, | ||
319 | journal->j_tail, WRITE_SYNC); | ||
313 | mutex_unlock(&journal->j_checkpoint_mutex); | 320 | mutex_unlock(&journal->j_checkpoint_mutex); |
314 | } else { | 321 | } else { |
315 | jbd_debug(3, "superblock not updated\n"); | 322 | jbd_debug(3, "superblock not updated\n"); |