Message ID | 20230216183906.54541-1-frank.li@vivo.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp466244wrn; Thu, 16 Feb 2023 10:42:56 -0800 (PST) X-Google-Smtp-Source: AK7set8RUdhwgiSrnR08c2egG5150vHV2JiXZVAwfs4n5Qg1A9Xbx1UeFQ6T+k2OIql6+3rFI0dh X-Received: by 2002:a05:6a20:441b:b0:c0:af73:be4d with SMTP id ce27-20020a056a20441b00b000c0af73be4dmr8390572pzb.54.1676572975733; Thu, 16 Feb 2023 10:42:55 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1676572975; cv=pass; d=google.com; s=arc-20160816; b=bJ0Xu37iXqeXtTXidBg7ygxDblJBE4PZbb2f2Cms0WbvoHhqReHTgXVA9P4+lEbW92 IPItREzCs2bBKmM2VauDXsqdNDTVdiTERBL7xVpGyOEaG0MwMl8ICfBM7m3zEsYxibwH v56autWCf4HGAMY+xm3PyjTawaciMOlrrCAZ15Yq0kloyFDKUS57PxoI0490OS4J6XHN 7voZdiZ3EzXdt8tpu0EHpQcQgrDmyFr5Amek6DGSvyQzRbuuEhcHM+mSzLRq3NLSrOi/ 04p9uEkLM5kDRmAyCNWUL0CJlAsWzsfn/c0vvTbVmqxtfp9qWsyya2vF9shvX3vH/Z8a l/yA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :message-id:date:subject:cc:to:from:dkim-signature; bh=PFbjTKmo/pXL2nDjChjaX+2/rnMGgJB5qneLMNYpgrw=; b=fV4YvtmkP+rdrud5am2GeZVNabZOn5w3Q8esCFUXXcYzkaGeLkpAIxMstQmphP0Akt DrM/zidoMLR6z3uJCo8ql4X8zYdrffFDPvTZ3rIwDpD3nr8+Xkahl0YOykYsLBTgvD+l +tpYwRjF6lnuLPGgZNQUPN61coYEM+Whu+JfZNWbd4paCsM5S2XmeyZsj8KFcWF+8FbK jLFXVrLjfFYnLzuWU58hiIv/0xEOLhMphHPz7vPcsG5hFky1guN7QrRVk2av8MorZfR1 aY7gBh1cl/kZmo182W7zoBXgDnVNzMwLOk6MjNc+5FBluOyc+mLQH5aA5fUPzMMWf04O B3ZQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=QrNuFm3Z; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r195-20020a632bcc000000b004fbd1dac629si1530924pgr.638.2023.02.16.10.42.43; Thu, 16 Feb 2023 10:42:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=QrNuFm3Z; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229587AbjBPSjl (ORCPT <rfc822;aimixsaka@gmail.com> + 99 others); Thu, 16 Feb 2023 13:39:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229508AbjBPSjj (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 16 Feb 2023 13:39:39 -0500 Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01on2110.outbound.protection.outlook.com [40.107.215.110]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9D3D75036D for <linux-kernel@vger.kernel.org>; Thu, 16 Feb 2023 10:39:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gbqNyrGtNr9dpUsEsjEDZXEU4PkdIDamw9oheHca6Q0C1FyLrG0EFvf1AWL16MQ6cyWcWbm8DHI0wW9DvPcb9VJTHCnuWmwmY1zJ9jJ9VigW38m26tR2HCvxutfMyvFEAxVtnkTYUcKUvbY8tJzXqThvD5GDWLrv1K9DhoHDO+vvi9FKjvQYzZ4kBP56iRMiR5suu9nRqt2xVOJfj4J3zAyjna/m7tBc7t/I+Ed2es//eUzPkJrX1A9G3E/pMWrUhr1ZMvSu2vNEOfgbg4itYUS9sOqh1NeAiIAlBu/cKPq9uM9LPA5e3TFUcv/fLzCGkwyBOZ9OJmexpgJi47fQ7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=PFbjTKmo/pXL2nDjChjaX+2/rnMGgJB5qneLMNYpgrw=; b=FQb+NM9nYQ1JrqvyfX0uDPQ5y3JsVN0CMnG7BWi5+Pn7TlB/EVi5HjjQs/jD3cdffGhpUpxEn+3eBWiF2GP7sxU+cCmH/SxcgTqHhHrtg4jLKHh6M13nyIg2fdNeVBMmGYqAiXjiLYOkHxYIxBeEXMI1DpOK2vEVC/mJRW40+swrjpSEax6Sv9anXFNepPZcSe5sl0xY6JrwgAfQi1MU4gx/DBfOVb0uL2Htt0vF/SWJRI9tcHEknUBbTDazZQBbzsZTv/CEUQ9H+eTvRbtxQUqb1MYRhRPPdzGOjGDH97c9U33pI2+LoLBi01C8f55RdnchP+PjAqKsnsNdDTaGSQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=PFbjTKmo/pXL2nDjChjaX+2/rnMGgJB5qneLMNYpgrw=; b=QrNuFm3Z/Pdk2l7eThx8laIgCODXCDaFTBcLXCs+3dGLoNBkFQYXKORuHJHBqGMHwAo8s7UrYQUCjl4x6G+y6aX1Pgj0iRnfGI3drNMOAIURf1m90Wtco1orW6mefrhYQ8MAl9Hfw6WqTgh93fdnWSJmCN6Sr4R33WzzE3OCzywefJ78uHWFtoOmdKYFf4ZJTFCI4oFlVE6XobOmn+cgnHwa4+IPxqOzC2+cnob0op3YDx1irhfRzhgUhDNMcncEQG29uZBNnJxLuFi8s6TWjCutphfBRF8kujRmz56sqhEhCmRdoXLpxtkwqD0LJ2eO/wiYrkPFm+s35obyyOJq/g== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from TYZPR06MB5275.apcprd06.prod.outlook.com (2603:1096:400:1f5::6) by SEZPR06MB5389.apcprd06.prod.outlook.com (2603:1096:101:64::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6111.12; Thu, 16 Feb 2023 18:39:16 +0000 Received: from TYZPR06MB5275.apcprd06.prod.outlook.com ([fe80::a2c6:4a08:7779:5190]) by TYZPR06MB5275.apcprd06.prod.outlook.com ([fe80::a2c6:4a08:7779:5190%3]) with mapi id 15.20.6111.009; Thu, 16 Feb 2023 18:39:16 +0000 From: Yangtao Li <frank.li@vivo.com> To: jaegeuk@kernel.org, chao@kernel.org Cc: linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, Yangtao Li <frank.li@vivo.com> Subject: [PATCH] f2fs: bugon w/ SBI_NEED_FSCK when has CONFIG_F2FS_CHECK_FS Date: Fri, 17 Feb 2023 02:39:06 +0800 Message-Id: <20230216183906.54541-1-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SI2PR04CA0011.apcprd04.prod.outlook.com (2603:1096:4:197::10) To TYZPR06MB5275.apcprd06.prod.outlook.com (2603:1096:400:1f5::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYZPR06MB5275:EE_|SEZPR06MB5389:EE_ X-MS-Office365-Filtering-Correlation-Id: 82059615-09be-4c13-8cd5-08db104d1b58 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4zrlI9R+KI8sJ6QlFwClOiVqPrEsbxfW36f8cQY1Cq1ZTt/oP0HIAhLhGmWvK7119ZnSiwFju8iPNUtpGT7b0dRXuTEYHdxt7XMWjXGoi8ZmXpTOTXnNfjgwXjhuoNBIg6VWMqk7oSxbVnkP4kCemfCVDwz5QgbvcbDXZDn17BbV0VzlpPU9oNxggd2PThjuQu+kz7TqeAsrJQgzDl+F91W69mq+FSbjhedrGqU+9qLaTzNWqeovnExx3y6TJXvVBggMzA0Y9fI76vqUXUkH95QAIC/tlSC45NTODpfZSo+R2k9kzn00gEhzostyXnJJ3lVB5HyiRfyv0HASH8XTMiptLD/Kyjy7/ywEDKtz9B+ro5BiczmlnZgd/vZl0lIv61XWwe05AtwZzo5klj+AWBiwpRaEfEW5eDSQLd2b2owKE21gL7Qnt7souC0rdfB5YyJrYNDQD2y5PzjtGI92JiG1DqWntlNOcSd+eNZQnlURs3XAbQtpBXnqzwki4VUBtsAJDZFYgUXmmA5mHrI+a58YrTiFyV9BP5T/c021urQ/PMOpz6jfJBOrieEN//OBuNVZZakKWIHP5JO+TPfY2WucLpQx0UVTVQtulQh9plb2L/KPaVeKlmqlbavgeoD1VTto+Xjj6K4TbUrfsklJOLb97avNGItfnWHNCPFrkGlx+wZz7Ii3ocZVuf9sF2+nUS+1Ok8u6KPnYQqzmCNtzw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:TYZPR06MB5275.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230025)(4636009)(39860400002)(366004)(136003)(396003)(376002)(346002)(451199018)(36756003)(86362001)(4326008)(66476007)(66556008)(66946007)(8676002)(38100700002)(38350700002)(2616005)(186003)(52116002)(6486002)(478600001)(6512007)(26005)(6666004)(8936002)(6506007)(1076003)(4744005)(316002)(5660300002)(2906002)(107886003)(41300700001);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 0MfCrvn0wf6tQGrgiCiLiHRp8jQajnCFbFYxgrt/TsVpsBHBIP9DVRKJsFAt5VlEWpnea+MzgZmFLf6zebc9FAG70mtWpAMDB0M6MJZNbZHuaApMx6fWwW7NNfvi1qE/DPEitr7lcAMKoUYHL8z62Kc0+73GHpWpCH2qP+ZJ+PqO4oxH5jKTMKybwX1BdxZujPguSey/y8KID1lOWOMHfn3pN5MtizbO0L6s7Qv7psPQ8RKW+TVbCUF6WdFif9o+P8nVcCkJXhSCTYumovEpo+I6xcnGgt9P1+yaP1k8Lkmv8Oktx+jmGPXxWzD1mxP6n4R9Bl9l2h9JKSkef1dE7GCf6MD1Gp3I0YwP9dxWaSdjCQQ+1A8ndP+34jd/DlaCdt4MVGVepBNFCcJbFgtQTo43Bw+1SDVAhptPqxjHM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RmPG9IJ2+LnIn5pVTnvRKvyhW6YuHzOfuzYY6qXqpwIyOB3n4W0h/YIiADKgA4hkaF19s80WKibSTGt3 X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 82059615-09be-4c13-8cd5-08db104d1b58 X-MS-Exchange-CrossTenant-AuthSource: TYZPR06MB5275.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Feb 2023 18:39:16.2715 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: YnoAbyx4WbxFtkXtAjkffVerugHwfFnx1JMsvJ+DMvxB9Gv4dWHs+gdcgcbPcPTUWwIQ4dVMKCRuE4yQ7skz6A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SEZPR06MB5389 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1758014185006578437?= X-GMAIL-MSGID: =?utf-8?q?1758014185006578437?= |
Series |
f2fs: bugon w/ SBI_NEED_FSCK when has CONFIG_F2FS_CHECK_FS
|
|
Commit Message
李扬韬
Feb. 16, 2023, 6:39 p.m. UTC
The SBI_NEED_FSCK flag usually means that the data in the
file system is abnormal, and the fsck tool needs to be used.
When CONFIG_F2FS_CHECK_FS is enabled, let us trigger bug_on
at the first moment when SBI_NEED_FSCK is set, so as to
analyze the first scene.
Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
fs/f2fs/f2fs.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h index 21596e0266ba..055bb7246a1f 100644 --- a/fs/f2fs/f2fs.h +++ b/fs/f2fs/f2fs.h @@ -2074,6 +2074,9 @@ static inline bool is_sbi_flag_set(struct f2fs_sb_info *sbi, unsigned int type) static inline void set_sbi_flag(struct f2fs_sb_info *sbi, unsigned int type) { +#ifdef CONFIG_F2FS_CHECK_FS + f2fs_bug_on(sbi, type == SBI_NEED_FSCK); +#endif set_bit(type, &sbi->s_flag); }