summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorHarshad Shirwadkar <harshadshirwadkar@gmail.com>2020-10-15 13:38:00 -0700
committerTheodore Ts'o <tytso@mit.edu>2020-10-21 23:22:38 -0400
commit0f0672ffb61aebac906cf0aa1607d1f07f266fb6 (patch)
treecd6099695b42c9b19e9121c091f4d1be879512cd /fs
parent8016e29f4362e285f0f7e38fadc61a5b7bdfdfa2 (diff)
downloadlinux-stable-0f0672ffb61aebac906cf0aa1607d1f07f266fb6.tar.gz
linux-stable-0f0672ffb61aebac906cf0aa1607d1f07f266fb6.tar.bz2
linux-stable-0f0672ffb61aebac906cf0aa1607d1f07f266fb6.zip
ext4: add a mount opt to forcefully turn fast commits on
This is a debug only mount option that forcefully turns fast commits on at mount time. Signed-off-by: Harshad Shirwadkar <harshadshirwadkar@gmail.com> Link: https://lore.kernel.org/r/20201015203802.3597742-9-harshadshirwadkar@gmail.com Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs')
-rw-r--r--fs/ext4/super.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/ext4/super.c b/fs/ext4/super.c
index 9fcf1e3dfe76..5308f0d5fb5a 100644
--- a/fs/ext4/super.c
+++ b/fs/ext4/super.c
@@ -1719,8 +1719,9 @@ enum {
Opt_max_dir_size_kb, Opt_nojournal_checksum, Opt_nombcache,
Opt_prefetch_block_bitmaps, Opt_no_fc,
#ifdef CONFIG_EXT4_DEBUG
- Opt_fc_debug_max_replay
+ Opt_fc_debug_max_replay,
#endif
+ Opt_fc_debug_force
};
static const match_table_t tokens = {
@@ -1808,6 +1809,7 @@ static const match_table_t tokens = {
{Opt_init_itable, "init_itable"},
{Opt_noinit_itable, "noinit_itable"},
{Opt_no_fc, "no_fc"},
+ {Opt_fc_debug_force, "fc_debug_force"},
#ifdef CONFIG_EXT4_DEBUG
{Opt_fc_debug_max_replay, "fc_debug_max_replay=%u"},
#endif
@@ -2040,6 +2042,8 @@ static const struct mount_opts {
MOPT_SET},
{Opt_no_fc, EXT4_MOUNT2_JOURNAL_FAST_COMMIT,
MOPT_CLEAR | MOPT_2 | MOPT_EXT4_ONLY},
+ {Opt_fc_debug_force, EXT4_MOUNT2_JOURNAL_FAST_COMMIT,
+ MOPT_SET | MOPT_2 | MOPT_EXT4_ONLY},
#ifdef CONFIG_EXT4_DEBUG
{Opt_fc_debug_max_replay, 0, MOPT_GTE0},
#endif