From: Zhang Yi
mainline inclusion
from mainline-5.14-rc1
commit 16aa4c9a1fbe763c147a964cdc1f5be8ed98ed13
category: bugfix
issue: #I3ZXZF
Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?i...
---------------------------
Export jbd2_journal_[un]register_shrinker() to fix this error when
ext4 is built as a module:
ERROR: modpost: "jbd2_journal_unregister_shrinker" undefined!
ERROR: modpost: "jbd2_journal_register_shrinker" undefined!
Fixes: 4ba3fcdde7e3 ("jbd2,ext4: add a shrinker to release checkpointed buffers")
Signed-off-by: Zhang Yi
Reviewed-by: Jan Kara
Link: https://lore.kernel.org/r/20210630083638.140218-1-yi.zhang@huawei.com
Signed-off-by: Theodore Ts'o
Reviewed-by: Yang Erkun
Signed-off-by: Chen Jun
Signed-off-by: Yu Changchun
---
fs/jbd2/journal.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fs/jbd2/journal.c b/fs/jbd2/journal.c
index 2f17757fa31f..d6759cd93268 100644
--- a/fs/jbd2/journal.c
+++ b/fs/jbd2/journal.c
@@ -2028,6 +2028,7 @@ int jbd2_journal_register_shrinker(journal_t *journal)
return 0;
}
+EXPORT_SYMBOL(jbd2_journal_register_shrinker);
/**
* jbd2_journal_unregister_shrinker()
@@ -2040,6 +2041,7 @@ void jbd2_journal_unregister_shrinker(journal_t *journal)
percpu_counter_destroy(&journal->j_jh_shrink_count);
unregister_shrinker(&journal->j_shrinker);
}
+EXPORT_SYMBOL(jbd2_journal_unregister_shrinker);
/**
* jbd2_journal_destroy() - Release a journal_t structure.
--
2.22.0