1 jbd2: don't write non-commit blocks synchronously
3 We don't need to write the revoke blocks and descriptor blocks using
4 WRITE_SYNC, since when we issue the commit block, thos blocks will get
5 pushed out via REQ_FLUSH. This will allow the journal blocks to be
6 written in fewer i/o operations (otherwise we end up issuing a whole
7 series of 4k writes unnecessarily).
9 Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
11 fs/jbd2/commit.c | 4 ++--
12 1 file changed, 2 insertions(+), 2 deletions(-)
14 diff --git a/fs/jbd2/commit.c b/fs/jbd2/commit.c
15 index cf2fc05..fb64629 100644
16 --- a/fs/jbd2/commit.c
17 +++ b/fs/jbd2/commit.c
18 @@ -554,7 +554,7 @@ void jbd2_journal_commit_transaction(journal_t *journal)
20 blk_start_plug(&plug);
21 jbd2_journal_write_revoke_records(journal, commit_transaction,
22 - &log_bufs, WRITE_SYNC);
24 blk_finish_plug(&plug);
26 jbd_debug(3, "JBD2: commit phase 2b\n");
27 @@ -739,7 +739,7 @@ start_journal_io:
28 clear_buffer_dirty(bh);
29 set_buffer_uptodate(bh);
30 bh->b_end_io = journal_end_buffer_io_sync;
31 - submit_bh(WRITE_SYNC, bh);
32 + submit_bh(WRITE, bh);
35 stats.run.rs_blocks_logged += bufs;