From: Chao Yu Subject: [PATCH 1/4] f2fs: fix to show injection rate in ->show_options Date: Mon, 12 Jun 2017 09:44:24 +0800 Message-ID: <20170612014427.40692-1-yuchao0@huawei.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from sog-mx-2.v43.ch3.sourceforge.com ([172.29.43.192] helo=mx.sourceforge.net) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1dKEPc-0006O9-Ot for linux-f2fs-devel@lists.sourceforge.net; Mon, 12 Jun 2017 01:45:00 +0000 Received: from szxga01-in.huawei.com ([45.249.212.187]) by sog-mx-2.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1dKEPb-0006lj-S1 for linux-f2fs-devel@lists.sourceforge.net; Mon, 12 Jun 2017 01:45:00 +0000 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linux-f2fs-devel-bounces@lists.sourceforge.net To: jaegeuk@kernel.org Cc: chao@kernel.org, linux-kernel@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net If fault injection functionality is enabled, show additional injection rate in ->show_options. Signed-off-by: Chao Yu --- fs/f2fs/super.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index 02cda00284e1..1c05763616b2 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -995,7 +995,8 @@ static int f2fs_show_options(struct seq_file *seq, struct dentry *root) 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"); + seq_printf(seq, ",fault_injection=%u", + sbi->fault_info.inject_rate); #endif #ifdef CONFIG_FS_DAX if (test_opt(sbi, DAX)) -- 2.13.1.388.g69e6b9b4f4a9 ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot