Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp1027370pxb; Wed, 6 Apr 2022 07:03:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwfMMePxYbg2NLmM02GIkgbtDiXGlgq2C9v8jGeclZOKXaQE+HN28kizoMeX/6wvw27mvK/ X-Received: by 2002:aa7:9019:0:b0:4fa:7532:9551 with SMTP id m25-20020aa79019000000b004fa75329551mr8995328pfo.26.1649253822173; Wed, 06 Apr 2022 07:03:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649253822; cv=none; d=google.com; s=arc-20160816; b=zf+OaA7sN82otzeUKXjn+U4Akq5tuLZTq3Wrej+vHIBRC/ylFD6xBM3P6WF+nPpOXf QGxB78W2/9MZRe/sMdXSiWbaIT2D+V5WM4NOvKJ/Ha2OjLGicUU9AAGiK1DFWWag66W0 Wf2OllgQVwHWXmrhgw3P5PTjj6rOUwVTtyv/r72o6hSL3lzC+Ofn7vJhmfSsPH+3SvAl 5x28dkf+qmXojTQHNo4UGdRY7S4jUGm5hvNde9/C3qkC0rZ08XxKJYqFFiop6fNH8H7u 98/H2wrdt2LWvP2wtpahabvGXqAjamHl7OyaZwcz6TGglTdMfIhfBgZFanm1BZ2dAvAa nqXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=0Gdlqh6DcXt9MMZ9FbCG35xjCm4/E9SWaHfRPq5MvSM=; b=oxONhL//8ecYoY+yGsAdfdef4ANJpPbkFkTNPpdVSU/G9b93up4rrw2YE4uEmUqcDk b0i6jAaz0KwsUJ5aWsv324nyjriCmoIgqDFfdIYVqejGE20PyF0oQ81cQrmVJDF8ph6b xlgZVUPuKbzHXL+zYpyAw7VVATirufQQgF3GRCQDclj2InlJnZ6hO7SILl1w+xsCN875 g78d43q8DeDhC24Xh4M0FQVwNrbVwVZ3iTS5YRm2utnH75cKKNCZK8tFEhPmIWvqNiu+ bcckWv8/tvalYau+VdVD6wdyu9Q3AY1/ggVrxjQ5jfu+fMaYg2J6XJRRl0tr5BL4Qwwf p1kw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id u15-20020a170902a60f00b00153b2d16642si15611786plq.586.2022.04.06.07.03.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Apr 2022 07:03:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id CBA0E59F7D1; Wed, 6 Apr 2022 04:53:15 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241384AbiDFIe1 (ORCPT + 99 others); Wed, 6 Apr 2022 04:34:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51264 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1359317AbiDFId0 (ORCPT ); Wed, 6 Apr 2022 04:33:26 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 509CB18B30 for ; Tue, 5 Apr 2022 20:01:26 -0700 (PDT) Received: from dggpeml500020.china.huawei.com (unknown [172.30.72.54]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4KY8PS4LtzzQjJN; Wed, 6 Apr 2022 10:59:40 +0800 (CST) Received: from dggpeml500009.china.huawei.com (7.185.36.209) by dggpeml500020.china.huawei.com (7.185.36.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Wed, 6 Apr 2022 11:01:24 +0800 Received: from [10.174.177.235] (10.174.177.235) by dggpeml500009.china.huawei.com (7.185.36.209) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Wed, 6 Apr 2022 11:01:24 +0800 Message-ID: <25a24259-3ac3-81ab-1c28-f2a4886888b5@huawei.com> Date: Wed, 6 Apr 2022 11:01:23 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: [f2fs-dev] [PATCH 4/5] f2fs: get rid of stale fault injection code Content-Language: en-US To: Chao Yu , CC: , References: <20220401071909.505086-1-yuyufen@huawei.com> <20220401071909.505086-5-yuyufen@huawei.com> <0c134e0e-b2d0-0bc0-42fc-cd220ff77e72@kernel.org> From: Yufen Yu In-Reply-To: <0c134e0e-b2d0-0bc0-42fc-cd220ff77e72@kernel.org> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.177.235] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpeml500009.china.huawei.com (7.185.36.209) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 2022/4/1 16:28, Chao Yu wrote: > On 2022/4/1 15:19, Yufen Yu via Linux-f2fs-devel wrote: >> Nowly, we can use new fault injection framework. Just delete the >> stale fault injection code. >> >> Signed-off-by: Yufen Yu >> --- >>   fs/f2fs/checkpoint.c |  2 +- >>   fs/f2fs/f2fs.h       | 51 ++---------------------------------------- >>   fs/f2fs/super.c      | 53 -------------------------------------------- >>   fs/f2fs/sysfs.c      | 23 ------------------- >>   4 files changed, 3 insertions(+), 126 deletions(-) >> ... >>               break; >> @@ -1963,14 +1920,6 @@ static int f2fs_show_options(struct seq_file *seq, struct dentry *root) >>       if (F2FS_IO_SIZE_BITS(sbi)) >>           seq_printf(seq, ",io_bits=%u", >>                   F2FS_OPTION(sbi).write_io_size_bits); >> -#ifdef CONFIG_F2FS_FAULT_INJECTION >> -    if (test_opt(sbi, FAULT_INJECTION)) { >> -        seq_printf(seq, ",fault_injection=%u", >> -                F2FS_OPTION(sbi).fault_info.inject_rate); >> -        seq_printf(seq, ",fault_type=%u", >> -                F2FS_OPTION(sbi).fault_info.inject_type); >> -    } >> -#endif > > This will cause regression due to it breaks application usage w/ -o > fault_* mountoption..., I don't think this is the right way. Thanks for catching this. I admit it's a problem. But, IMO fault_* mount option are mostly been used in test, not in actual product. So, I think it may just affect some test applications. With the common fault injection framework, it can be more easy and flexible to do fault injection test. Therefore, I want to remove the two mount options directly. If you really worried about compatibility, how about just reserving the two inject_* options but without doing any thing for them. We actually configure fault injections by debugfs in this patch. Or do you have more better suggestion? Thanks, Yufen