aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jbd2/commit.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/jbd2/commit.c')
-rw-r--r--fs/jbd2/commit.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/jbd2/commit.c b/fs/jbd2/commit.c
index e0139786f717..a2ed72f7ceee 100644
--- a/fs/jbd2/commit.c
+++ b/fs/jbd2/commit.c
@@ -168,6 +168,7 @@ static int journal_submit_commit_record(journal_t *journal,
168 spin_unlock(&journal->j_state_lock); 168 spin_unlock(&journal->j_state_lock);
169 169
170 /* And try again, without the barrier */ 170 /* And try again, without the barrier */
171 lock_buffer(bh);
171 set_buffer_uptodate(bh); 172 set_buffer_uptodate(bh);
172 set_buffer_dirty(bh); 173 set_buffer_dirty(bh);
173 ret = submit_bh(WRITE, bh); 174 ret = submit_bh(WRITE, bh);
@@ -560,7 +561,9 @@ void jbd2_journal_commit_transaction(journal_t *journal)
560 * transaction! Now comes the tricky part: we need to write out 561 * transaction! Now comes the tricky part: we need to write out
561 * metadata. Loop over the transaction's entire buffer list: 562 * metadata. Loop over the transaction's entire buffer list:
562 */ 563 */
564 spin_lock(&journal->j_state_lock);
563 commit_transaction->t_state = T_COMMIT; 565 commit_transaction->t_state = T_COMMIT;
566 spin_unlock(&journal->j_state_lock);
564 567
565 stats.u.run.rs_logging = jiffies; 568 stats.u.run.rs_logging = jiffies;
566 stats.u.run.rs_flushing = jbd2_time_diff(stats.u.run.rs_flushing, 569 stats.u.run.rs_flushing = jbd2_time_diff(stats.u.run.rs_flushing,