diff options
author | Kaixu Xia <xiakaixu@huawei.com> | 2017-01-27 09:35:37 +0800 |
---|---|---|
committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2017-02-22 20:24:53 -0800 |
commit | 0cc0dec2b6f9bf0e69afbddc1c11e220a1cdf328 (patch) | |
tree | 0d47a38a52426dd35f7fc417a3cf939512f1fefd | |
parent | 73545817c90edcb367a65720f669cddce633bc46 (diff) | |
download | op-kernel-dev-0cc0dec2b6f9bf0e69afbddc1c11e220a1cdf328.zip op-kernel-dev-0cc0dec2b6f9bf0e69afbddc1c11e220a1cdf328.tar.gz |
f2fs: show the fault injection mount option
This patch shows the fault injection mount option in
f2fs_show_options().
Signed-off-by: Kaixu Xia <xiakaixu@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
-rw-r--r-- | fs/f2fs/super.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 9212281..f97e808 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -556,6 +556,7 @@ static int parse_options(struct super_block *sb, char *options) return -EINVAL; #ifdef CONFIG_F2FS_FAULT_INJECTION f2fs_build_fault_attr(sbi, arg); + set_opt(sbi, FAULT_INJECTION); #else f2fs_msg(sb, KERN_INFO, "FAULT_INJECTION was not selected"); @@ -946,6 +947,10 @@ static int f2fs_show_options(struct seq_file *seq, struct dentry *root) seq_printf(seq, ",active_logs=%u", sbi->active_logs); if (F2FS_IO_SIZE_BITS(sbi)) seq_printf(seq, ",io_size=%uKB", F2FS_IO_SIZE_KB(sbi)); +#ifdef CONFIG_F2FS_FAULT_INJECTION + if (test_opt(sbi, FAULT_INJECTION)) + seq_puts(seq, ",fault_injection"); +#endif return 0; } |