diff options
author | Jan Kara <jack@suse.cz> | 2012-03-13 22:45:38 -0400 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2012-03-13 22:45:38 -0400 |
commit | 3339578f05787259917788f461f4196b7349c2a4 (patch) | |
tree | 8e05b11eecd98e49076057940fc161f5b867b55c /include/linux/jbd2.h | |
parent | 932bb305ba2a01cd62809644d569f004e77a4355 (diff) |
jbd2: cleanup journal tail after transaction commit
Normally, we have to issue a cache flush before we can update journal tail in
journal superblock, effectively wiping out old transactions from the journal.
So use the fact that during transaction commit we issue cache flush anyway and
opportunistically push journal tail as far as we can. Since update of journal
superblock is still costly (we have to use WRITE_FUA), we update log tail only
if we can free significant amount of space.
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'include/linux/jbd2.h')
-rw-r--r-- | include/linux/jbd2.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/jbd2.h b/include/linux/jbd2.h index 876a7d87192b..912c30a8ddb1 100644 --- a/include/linux/jbd2.h +++ b/include/linux/jbd2.h | |||
@@ -974,6 +974,7 @@ int jbd2_journal_next_log_block(journal_t *, unsigned long long *); | |||
974 | int jbd2_journal_get_log_tail(journal_t *journal, tid_t *tid, | 974 | int jbd2_journal_get_log_tail(journal_t *journal, tid_t *tid, |
975 | unsigned long *block); | 975 | unsigned long *block); |
976 | void __jbd2_update_log_tail(journal_t *journal, tid_t tid, unsigned long block); | 976 | void __jbd2_update_log_tail(journal_t *journal, tid_t tid, unsigned long block); |
977 | void jbd2_update_log_tail(journal_t *journal, tid_t tid, unsigned long block); | ||
977 | 978 | ||
978 | /* Commit management */ | 979 | /* Commit management */ |
979 | extern void jbd2_journal_commit_transaction(journal_t *); | 980 | extern void jbd2_journal_commit_transaction(journal_t *); |