Skip to content

Commit 1cf5b02

Browse files
jankaratytso
authored andcommitted
jbd2: drop pointless shrinker batch initialization
In jbd2_journal_init_common() we set batch size of a shrinker shrinking checkpointed buffers to journal->j_max_transaction_buffers. But that is guaranteed to be 0 at that point so we effectively stay with the default shrinker batch size of 128. It has been like this since introduction of jbd2 shrinkers so just drop the pointless initialization. Signed-off-by: Jan Kara <[email protected]> Reviewed-by: Zhang Yi <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Theodore Ts'o <[email protected]>
1 parent 27ba5b6 commit 1cf5b02

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

fs/jbd2/journal.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1617,7 +1617,6 @@ static journal_t *journal_init_common(struct block_device *bdev,
16171617

16181618
journal->j_shrinker->scan_objects = jbd2_journal_shrink_scan;
16191619
journal->j_shrinker->count_objects = jbd2_journal_shrink_count;
1620-
journal->j_shrinker->batch = journal->j_max_transaction_buffers;
16211620
journal->j_shrinker->private_data = journal;
16221621

16231622
shrinker_register(journal->j_shrinker);

0 commit comments

Comments
 (0)