diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-04-01 13:57:49 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-04-01 13:57:49 -0400 |
commit | 395d73413c5656c6d7706ae91dcb441f9b7e3074 (patch) | |
tree | 7fadabe996f70d7918583fa2312d4fad19397fcb /fs/jbd2/commit.c | |
parent | c226fd659fa7b6a7b038df5ae6856a68514bacde (diff) | |
parent | 06705bff9114531a997a7d0c2520bea0f2927410 (diff) |
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: (33 commits)
ext4: Regularize mount options
ext4: fix locking typo in mballoc which could cause soft lockup hangs
ext4: fix typo which causes a memory leak on error path
jbd2: Update locking coments
ext4: Rename pa_linear to pa_type
ext4: add checks of block references for non-extent inodes
ext4: Check for an valid i_mode when reading the inode from disk
ext4: Use WRITE_SYNC for commits which are caused by fsync()
ext4: Add auto_da_alloc mount option
ext4: Use struct flex_groups to calculate get_orlov_stats()
ext4: Use atomic_t's in struct flex_groups
ext4: remove /proc tuning knobs
ext4: Add sysfs support
ext4: Track lifetime disk writes
ext4: Fix discard of inode prealloc space with delayed allocation.
ext4: Automatically allocate delay allocated blocks on rename
ext4: Automatically allocate delay allocated blocks on close
ext4: add EXT4_IOC_ALLOC_DA_BLKS ioctl
ext4: Simplify delalloc code by removing mpage_da_writepages()
ext4: Save stack space by removing fake buffer heads
...
Diffstat (limited to 'fs/jbd2/commit.c')
-rw-r--r-- | fs/jbd2/commit.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/jbd2/commit.c b/fs/jbd2/commit.c index 62804e57a44c..4ea72377c7a2 100644 --- a/fs/jbd2/commit.c +++ b/fs/jbd2/commit.c | |||
@@ -367,6 +367,7 @@ void jbd2_journal_commit_transaction(journal_t *journal) | |||
367 | int tag_bytes = journal_tag_bytes(journal); | 367 | int tag_bytes = journal_tag_bytes(journal); |
368 | struct buffer_head *cbh = NULL; /* For transactional checksums */ | 368 | struct buffer_head *cbh = NULL; /* For transactional checksums */ |
369 | __u32 crc32_sum = ~0; | 369 | __u32 crc32_sum = ~0; |
370 | int write_op = WRITE; | ||
370 | 371 | ||
371 | /* | 372 | /* |
372 | * First job: lock down the current transaction and wait for | 373 | * First job: lock down the current transaction and wait for |
@@ -401,6 +402,8 @@ void jbd2_journal_commit_transaction(journal_t *journal) | |||
401 | spin_lock(&journal->j_state_lock); | 402 | spin_lock(&journal->j_state_lock); |
402 | commit_transaction->t_state = T_LOCKED; | 403 | commit_transaction->t_state = T_LOCKED; |
403 | 404 | ||
405 | if (commit_transaction->t_synchronous_commit) | ||
406 | write_op = WRITE_SYNC; | ||
404 | stats.u.run.rs_wait = commit_transaction->t_max_wait; | 407 | stats.u.run.rs_wait = commit_transaction->t_max_wait; |
405 | stats.u.run.rs_locked = jiffies; | 408 | stats.u.run.rs_locked = jiffies; |
406 | stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start, | 409 | stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start, |
@@ -680,7 +683,7 @@ start_journal_io: | |||
680 | clear_buffer_dirty(bh); | 683 | clear_buffer_dirty(bh); |
681 | set_buffer_uptodate(bh); | 684 | set_buffer_uptodate(bh); |
682 | bh->b_end_io = journal_end_buffer_io_sync; | 685 | bh->b_end_io = journal_end_buffer_io_sync; |
683 | submit_bh(WRITE, bh); | 686 | submit_bh(write_op, bh); |
684 | } | 687 | } |
685 | cond_resched(); | 688 | cond_resched(); |
686 | stats.u.run.rs_blocks_logged += bufs; | 689 | stats.u.run.rs_blocks_logged += bufs; |