]> git.baikalelectronics.ru Git - kernel.git/commit
jbd2: don't create journal_head for temporary journal buffers
authorJan Kara <jack@suse.cz>
Tue, 4 Jun 2013 16:01:45 +0000 (12:01 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Tue, 4 Jun 2013 16:01:45 +0000 (12:01 -0400)
commit9766f215f0ba09554498982e2da0a35f80d20e5e
treea55e3eb4174ff0d17b9f0523619b9b647774b782
parentaf15c764b2a4135f0e6b8526f0f7f3ef460d7399
jbd2: don't create journal_head for temporary journal buffers

When writing metadata to the journal, we create temporary buffer heads
for that task.  We also attach journal heads to these buffer heads but
the only purpose of the journal heads is to keep buffers linked in
transaction's BJ_IO list.  We remove the need for journal heads by
reusing buffer_head's b_assoc_buffers list for that purpose.  Also
since BJ_IO list is just a temporary list for transaction commit, we
use a private list in jbd2_journal_commit_transaction() for that thus
removing BJ_IO list from transaction completely.

Reviewed-by: Zheng Liu <wenqing.lz@taobao.com>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
fs/jbd2/checkpoint.c
fs/jbd2/commit.c
fs/jbd2/journal.c
fs/jbd2/transaction.c
include/linux/jbd2.h