From patchwork Thu Oct 27 12:08:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 11756 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp197494wru; Thu, 27 Oct 2022 05:21:56 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5vE7bCJBCsbK8cFUyq8Z5rcFBheKsTGrK+vB+vuWoH4LZgiS1RrzPImyJLn0OswO9YWTh8 X-Received: by 2002:a17:90b:1b03:b0:20d:ac3b:f1dd with SMTP id nu3-20020a17090b1b0300b0020dac3bf1ddmr9784102pjb.121.1666873316473; Thu, 27 Oct 2022 05:21:56 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1666873316; cv=pass; d=google.com; s=arc-20160816; b=MEcgvMoBzaEi8cLMWOqClXb1mXHfpD6HQiaCa1A1hgXkZy1VXdrMo8RKBGLXkctt5P bymGrnPXA6ysyLNlA5KegOSxxLkS38Dc0eccl4t9oYJ06iXrjqgCpuT2oMMGAYvzXYZX 4CejIHSlZ9xkdgwd3y39IgvMZK7ztz90Jifyg3E/u2L7zAyRFBJzed1DtbcYYw7c5fBH YmY1F6fNfOJV/XpggiChuYocqQnXPiHaNMrI4dfcxjDrQ1ARks7nf52uedEF01JQf7eN yJwxkiDZRa5tXMuffvTXnF4ZsOLY89NL65VcQ0ZvcIPAetaGbUnbi2Xyx5xQ4ngH1mk6 pWkw== 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=+YtFBksY2m45tgD3PKbTXJC+mVQ36+UJNFhpAC0UhIU=; b=HDAilt0tYiO8pYII7CAr6LhhYmqtKQZC3+V8J255MkMT9toZv7JiDDSmq7kMMjusZc sncTtSW1jUCJSJKipDcBt4LXNkaq6Llufig0vW4r6A6u8FHrVnVDinnS5vDqUi4pR3nF xI9NZovpRGcVNcaB+J4DQk972dzT8PbMyplFYK3OYfFuLqxLT8iTMKDnyLF4V8v30EAN gImB6BCnDMFZLFIGvYDx2bEA+ssyFWzBX6xFrR4w0GKLTLXJnPwQ2cnCjVJOfAOiQ5m6 vhPQvb7kgI0+ysPc3HhsCxzkchr40KfQ+t7g0lwQ2IPoIS7wCJneC5zO1sSrJ833Nqj7 T4wg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=a9M3bWpM; 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 144-20020a630696000000b00457523c57bcsi1215885pgg.354.2022.10.27.05.21.39; Thu, 27 Oct 2022 05:21:56 -0700 (PDT) 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=a9M3bWpM; 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 S235566AbiJ0MIY (ORCPT + 99 others); Thu, 27 Oct 2022 08:08:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59852 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235551AbiJ0MIW (ORCPT ); Thu, 27 Oct 2022 08:08:22 -0400 Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01on2125.outbound.protection.outlook.com [40.107.215.125]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5A196B03E8 for ; Thu, 27 Oct 2022 05:08:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=gbg/8c0H5LKQTL5yTaJoMnzvYdPoNVYAfZLHkstV/X2WvQsnkmxKWYSLPkTGUlSooHHN6bXlTdzER64z0d6PmNqzousbAV2tnCcbasVMJbOlrZ0X7ZRShCrjGl0g3MocICYzk/nmRy4qzbWw++Y+w6haiqZy1jKgythdz1RdmH6NWOtYghHZeAERmcQu5WOfMgkbLdxT6H40LeJ2jWG1h9ynZhiqF5LQMfScijqSutkyQOWji97rJVTZ1HT1CkMdBTQraWnSSKtSMN0VRaX4Mr2eo5RnJc6I9S4dB/5un68jfY1DrOH6cH9nzzHk3Zg3r59784AOWHZPdyJ2Fy4bUg== 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=+YtFBksY2m45tgD3PKbTXJC+mVQ36+UJNFhpAC0UhIU=; b=oepfvvkEUD64sOEeuAux1WEsFmjJR/QASHpXAu4kQtClY/VlsBb7kohexL/PZxY7/aUCcUNLliScn/daur4DuW53OZMckNP/evL6M/dymH93h+7AjS2Xrm8FgwLdesNvvxBYvPXIjbRZw6nwM7Q8baxmzeoOh+5LvhZBYjxGNGB32MQKwi863jlYhahKpDAG+QviZZPwg4AT/xBpqGDyBCZ7bfhRTEvGW+HFUwELX+K5LLcNWQ5xGM06MADNhkQBK0DmjjlI4w5wyrP/NaoaZr240AvD2UKt8pkUOejhqSSd9CLjp+GHXKLhb3WrjcH27maJ2wo7kC7eXB+m07BHCw== 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=+YtFBksY2m45tgD3PKbTXJC+mVQ36+UJNFhpAC0UhIU=; b=a9M3bWpMnlXK0uxCVZKBFfYniltp0YTAXMys8jylO4+H1woRzAg12c8sPMF6hrxn6BQl2SEKjfEhyBQce5p+5KWcUc+WZ6PEbXYpkyxUmtKKNyfjdrfG9/HVn3LqppFqV7x8xdIUvWmgNsLdEwUDVvuv10+DaAyXxOGa08ll7Dj02OaYSSoKY7XND9MwQAOW8M3klQauvej3LV0Izu13BNLp6kGDekWBR7BRqDdDN4r3WWOVBym8UzntYM1h8ao/opiqAhmxptbD2fsDI/dvCYxQQe9tvviy3svEGkgqUJLlBMFYpEF0M7OLjlQAQyWa15T04mwNM5EdZ9vvgxm1Jg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4468.apcprd06.prod.outlook.com (2603:1096:820:73::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5746.28; Thu, 27 Oct 2022 12:08:18 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::c84b:5a6c:d66f:c0fd]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::c84b:5a6c:d66f:c0fd%3]) with mapi id 15.20.5746.023; Thu, 27 Oct 2022 12:08:18 +0000 From: Yangtao Li To: jaegeuk@kernel.org, chao@kernel.org Cc: linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 1/3] f2fs: rename flush_error_work() to f2fs_record_error_work() Date: Thu, 27 Oct 2022 20:08:05 +0800 Message-Id: <20221027120807.6337-1-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 X-ClientProxiedBy: SG2PR01CA0187.apcprd01.prod.exchangelabs.com (2603:1096:4:189::12) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4468:EE_ X-MS-Office365-Filtering-Correlation-Id: 6a795a56-99e9-4dbd-06cc-08dab813eedc X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: b9z7lCcxZT0ejF9rp4ip75V7Mqwbch4efHFEsYXClSKhPnYiUiIZfXAttwUYkJapHNDmTyYMp4v6Cglp1OiY1c7UhwUDZDc3d7mESpKKci0KtZ6NIWdpAFZzFaYQDrhf2qBRGdyQGMhdLJg71nFHobnEpbmWsmjLzcoG7SjbJ2Bn+5UIPk+fpm6ZFeP5dSL4t2MWBQlSmxIXIYlRVel23BpdPA8ahD8rIBFGIb2U9320P/n8UZHxCGvEj9W7Hd1FOOnH0pUJNxaiQ3MrhheTZpksSdvRwQbCJfmG9Qzlfg+5pXOo5qRG9Is8Sa135M2rV9IhHUq/Xbfdf09S7nmWpuFGSnIsumq4oAfD/Uz8/wskUZAF4aEYDi5TNYKOdzl/jwLJ+52t/TnoUCw2XPHGiwGvg5y0wtyshdgHhUiohT15SPZDau3UOX+Ozww3u7zuxKiaatLPR3g7ZPQFocY4H842DBFDZUt2vZcfT5Y43oyIVp7mKiSF7NXYjKWMtuEvFmK7UP3TVoaqbKgNnpsO/tsLp4uqOBjMlL203JBhArXtK/X+7SFZqNxhQaiJm3O2qkAEgX0CmMcDRQUWPe/NPYH8V8eYu6lbMlEKCZGi5eP6eAfHFutajR8zcfRvKv4LD1FP0BGric/7ExfALPuUn3G+QGW303GvXCSyDI3X9wTF77ot3R0AszSkFszdVl01ySYvSpjPYzQ9nBL9oyG1mz6S6+BEnK/dlH0G3SqIRkJTBMgfZYOgej4XY+kUAWJkuskuRCupqxzSRehuvqhRVg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(346002)(39860400002)(396003)(376002)(366004)(136003)(451199015)(36756003)(186003)(1076003)(6486002)(52116002)(83380400001)(6506007)(6666004)(478600001)(107886003)(2616005)(5660300002)(8936002)(66556008)(4326008)(26005)(38350700002)(38100700002)(316002)(6512007)(41300700001)(2906002)(66476007)(8676002)(86362001)(66946007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 3f8JQ4tu6Yha8D3F0WNv384iSNrgtijNsSCvkqFnVoy64YF5oqCqveiJ36252DOuJ2S8SLURQrNzh24cCb4OFqmn6p2LmbE9EYoQll7oMcGQi0jKuZAPUcECcQSNL8zzcvvu4Whe1lxFWa/hzzot41KnzZz4+npsrhRPA1t5mLHz66FRcTymeV1ineO9BDIR5N0ExIfY2FkZvTmy7mjStR/3ksCvkbwXgVkRP2PK7k3ZzeDW97Av41ofBhHx7pkaXYt9Pv30mO489WAr/OQ/qnMWpIecvzvAV4kjpPXb6U9a5O3X3zigInMg/WQqk6+omLyZseySruPK7qN3XDgsLvCKkbML6Ms58v4BZvHLzMSjR39JTbbs30wE8xHq3bDGW5M6p9FdKFxVZebO9oTpa7FWCHwB1ujfC/ROHUWkq4wwUVdqMaFS8A5J9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zVl8PWBptYEaWJVif5tzLIPFwlkE1brxM/r1HD7lOstTUS+Pm6+mv2mq5p+crDuN X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6a795a56-99e9-4dbd-06cc-08dab813eedc X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Oct 2022 12:08:17.9675 (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: 3IgFmGvEP0H7Lq9RBYKYleIZK+zuETQVpGaSoI9nFYYBKPOWoJMlUfDISELVuIKEvRUH6Bh4AknT14sriiDFGg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4468 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747843354815087594?= X-GMAIL-MSGID: =?utf-8?q?1747843354815087594?= Since it is an f2fs module, it is best to prefix function names with f2fs_. At the same time, there is already a flush thread and related functions in the system, rename flush_error_work() to f2fs_record_error_work(). Signed-off-by: Yangtao Li --- fs/f2fs/super.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index a241e4073f1d..fc220b5c5599 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -4019,7 +4019,7 @@ void f2fs_handle_critical_error(struct f2fs_sb_info *sbi, unsigned char reason, f2fs_stop_discard_thread(sbi); } -static void flush_error_work(struct work_struct *work) +static void f2fs_record_error_work(struct work_struct *work) { struct f2fs_sb_info *sbi = container_of(work, struct f2fs_sb_info, s_error_work); @@ -4374,7 +4374,7 @@ static int f2fs_fill_super(struct super_block *sb, void *data, int silent) goto free_devices; } - INIT_WORK(&sbi->s_error_work, flush_error_work); + INIT_WORK(&sbi->s_error_work, f2fs_record_error_work); spin_lock_init(&sbi->error_lock); memcpy(sbi->errors, raw_super->s_errors, MAX_F2FS_ERRORS); memcpy(sbi->stop_reason, raw_super->s_stop_reason, MAX_STOP_REASON); From patchwork Thu Oct 27 12:08:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 11757 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp197651wru; Thu, 27 Oct 2022 05:22:12 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7jlPvaBA6vkD20Q9cCwjCrLLqmn4EmM42sxIrXz8wId43BwIaGwAcbW+mVJ+WANGNrPiZt X-Received: by 2002:a50:a44c:0:b0:45c:6451:363d with SMTP id v12-20020a50a44c000000b0045c6451363dmr45486332edb.115.1666873332604; Thu, 27 Oct 2022 05:22:12 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1666873332; cv=pass; d=google.com; s=arc-20160816; b=BvuO5raZl7Qj3jGrXX0BNyV9E7Ks3lCziLN9VAeTQALkrgqVcKN1ru6C/R6EkovccV +9ntnNOnffQAqBHADCuEFyaTT8eSexqfMIb5DVSr1EeoEfR0Sd1iIk8OlyPBY/pszevI BWu4nAX9uIKElH+qnUPyD3bbm9Dc8NYN8oQyBiVy5gtLtJLPyxjWkQ29hwMIpf9rClRu SU7QECuVKQhOWoDLwRTkR/VAtnYwq3wyGRFmja8mSt2QCwqk8oPdXa2BFWbyBovLi2QR d/kNqjSO/OP4xSWSoxQ3dz/BOWarBSS3OZWDphns4bI+xKk6HysJ2b3wdlBEWpzDCagB L8ow== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=1OXBOAw2l2D4avQ5PTQbi02Y+avM5lguj95jUokE9Oo=; b=evaZJGoU6Ly+g1IqMeBwJy19zZUlmyWhoR3xCpy64PXy6JEjfwK9wPadbjimmxoATx rUml+FvQYs7Dj/9wEkBVb/mFCrqdfRUsI12A86mgg92ROo4/37qPTpNiwPAE+yebmVfA xW8KMbLXsVriwkKkYXZApKDivuhGeYpnyey+2ivtAworelU2RmunVqI4gscVg73JGvg4 kzBtvyXHqxBamT4fth4nroBxe2FmTlGcUpKClgEpNGGZ616Qb/qeEmiCiXi1LM+dgOkw H1pO+jWklmHGgs0mx9GwtB26iSFLKfxGa5S6H9NxQKPNid+b0F/BWIplvB7gqoT7iVHH uz3g== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=n6OWoKnI; 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 o21-20020a170906975500b007707b853e46si1325496ejy.882.2022.10.27.05.21.44; Thu, 27 Oct 2022 05:22:12 -0700 (PDT) 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=n6OWoKnI; 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 S235571AbiJ0MI0 (ORCPT + 99 others); Thu, 27 Oct 2022 08:08:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59876 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235475AbiJ0MIX (ORCPT ); Thu, 27 Oct 2022 08:08:23 -0400 Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01on2125.outbound.protection.outlook.com [40.107.215.125]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 71AFADCE81 for ; Thu, 27 Oct 2022 05:08:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZBo1kqs4XgNjF96OMqDBayvLG5CxOA7q0k38N6e4TM8B/wi3Hm2T4vPsj8etnu49PpYoXJ7PeIxhGAx33vwkIp4gu1ZLxxx7ZsSJv28Oh6srkj099FI9qcFoKjS9AQtntKmMjhPcZf1AmJAKAIGosI6jktoAVYtUYbQF+ftF6EQxwfaoMtTnflvsRc7+3gKulPQ19LMCEXS7YOtCLk4F9HU5HMtg1qaKFwv1mbz9MJesl0xklNDHawlTTUeSSAXpvpaQyoW5FZ6BdrGtSPpkcHDNpkUy0zAe+bIa+kPYQbZ5e3yVUNsQoNs4vLceRKIxjIIwunvJC2eQI0rXDlzmow== 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=1OXBOAw2l2D4avQ5PTQbi02Y+avM5lguj95jUokE9Oo=; b=C6EaIg8+2zngQAl877hTOpU0w77cBeMOcoc0EnLUcVJSF/Q1mcfnP2ytArZ/wd7TXWOLSRxxG5dEDAepAeU+uCbC3U9XUOSXdhILq5AUw6rAs55Q1qqQ6gKFOZ0KHSOLkQaKs4vwgJUuiN1acTvV1+TwqlwOia7dlchvgvPNruM+m5VIHxz8VpIs8ctbbmhffmxrV7TqImLNm5urSAXYWLYjSpXa6oOVq8MocjQwuLRhshfFRFG3An4oLrg+n+Fbfwqp2R0YtvSMhleIgKW8t/5cpMXs2Z6jXBE+I8YiXwKVgHmFcjDmiFkSqkVJDbUoPAfZf48TR+OMitb90bDRYw== 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=1OXBOAw2l2D4avQ5PTQbi02Y+avM5lguj95jUokE9Oo=; b=n6OWoKnIP9Zi9sKuOa2fag2xaQFiJClNjTHipo0jglZ6NRbC2/jGAJJfiEF3zf2sI4ad992W4GK5ixY73BNV1kL16bJGYEFmLx4nz9Qd16Yyit+KHrD0DfUnuqVvVH9rZ9gAHP8YjamltPGKhcb00rXPqdR9RrhMFe4H02UrdV1v8alj8FiMfRGhibOGURayS/Kovm9RZhlnk93oH6tz/LPr1JFo5hi+iX5Lfeait1jE7p50rED2V7EKkeAzCRf4QJtrYfnO4KcVAqO+d0uVn2pHCbS9nQzNrJ1xmTTEdn6IUWellaJPAJcrFnl/Yl/cX9P6aZNJjsamiFqRv7/CYQ== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4468.apcprd06.prod.outlook.com (2603:1096:820:73::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5746.28; Thu, 27 Oct 2022 12:08:20 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::c84b:5a6c:d66f:c0fd]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::c84b:5a6c:d66f:c0fd%3]) with mapi id 15.20.5746.023; Thu, 27 Oct 2022 12:08:19 +0000 From: Yangtao Li To: jaegeuk@kernel.org, chao@kernel.org Cc: linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 2/3] f2fs: export f2fs_stop_flush_thread() for external use Date: Thu, 27 Oct 2022 20:08:06 +0800 Message-Id: <20221027120807.6337-2-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221027120807.6337-1-frank.li@vivo.com> References: <20221027120807.6337-1-frank.li@vivo.com> X-ClientProxiedBy: SG2PR01CA0187.apcprd01.prod.exchangelabs.com (2603:1096:4:189::12) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4468:EE_ X-MS-Office365-Filtering-Correlation-Id: e345eb4a-0602-46ab-5d02-08dab813f019 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: FgUAfatVUNe1c/9QplJvK8icFzaZJHTPt4JZdwUOHX/Thd6PnSo+eWADMQxVWrzOydIRSk4A9Ra9TRorysGj/RZcshcUUx8iFCAIsj4oH/lHl0HCDuAGGp+voKfqQugdfyLcoS2qgm1JqtE6+yjI3FJllOOfwA5UBEzB85qZtLXVogamVrTNEMZHPPJ4AaqaMUUXtArQC3Y8KXXJlEeHnz58gi5YfUTmO+XrFxPz6UA97gkp2RiFuGnr8fqcgtPcI025RzqTYH2JIwA1YV+ISAl04ODmnScjMNrKAjk6g9o7kjaY9UlD1dJNxheTOaVzl+rcaPOGvRMlYPPFGGHX3PnEJyMku0XlfvxaIbtB7ByKSyQcElraEs55mp6XQs3Sfjp3Uw1mFDF6SmmeblGSdZmJOX30YuyLzseSZhMdDUvIafkg8cqFDxGgqhHshvvq1ejGQqAQBNncxUNZTzc74G3upQLc1s25+v/uQy026gQ1BwPcYojNp99PhK34zabpDME74yIMry9YWYz9rIXBQa1jVQ23UR8sk1xOMZcd6897836KlxLAcXU1PpZlmKOF0C87XzjvGPt80cGXF53mExycMC9nQ/IrG4V0TdiC8w2qpuzfh7AE69dbXy4+NgQ5a60QviEUhNIbsufBvZfnPbRBDTBz241YSkCGhmteWR8a9btz1JLZIt2usUmt0DLdRyeQKgYE7vX1um5Yt+KFqeGN0Z+z0fs5jowKHciCtqlhv8nbYCp57cpxthlRVLojIcVacRGmadxWXkTwAvTMYA== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(346002)(39860400002)(396003)(376002)(366004)(136003)(451199015)(36756003)(186003)(1076003)(6486002)(52116002)(83380400001)(6506007)(6666004)(478600001)(107886003)(2616005)(5660300002)(8936002)(66556008)(4326008)(26005)(38350700002)(38100700002)(316002)(6512007)(41300700001)(2906002)(66476007)(8676002)(86362001)(66946007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-Ant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eEXgPn1T71oeG+70EaEliupIRIzD/6t/r+mUbzxsIYDEO5Ux6NrcuDhBtCgQC0aE9qc191eY8UL4TTroai7DkYO9U8Gjev6Ie+BHraPAWbl4Msg/zrYfe9X5nj92RrKwU9C+nP1vMP9bYHa6OKff3GNutjGPFC++xkCrZ4ahxXl9/q6028LaRkUezUgMHGYprE7PzPV/UPHlqhPExRU2ixAROCQMXtedDeo2aRazESt5jtTEZK2XzrXEQvWe5GhYJ3OAixmwRo1EUrwKaUwpSbndMoMkLHsMD3Jel+F5cGokEFPCDsqFqzJQz5xYAyQtNMi6iiveodrTjodeY7HILGQcer8GmNaeTxQQPWmsVc4eyFRyLxQ542RtbedSfzcsU+tJGj8Zxp2PwC6BMhUSQFOoDBZHyFB1/as3Y48AkI8R2jY/Fa6OxvO5PghoYzz1DPyXxX+CCChmPxdHFMeT9zzMcZOjVqOkKVvDy3tl/gg0suBDp0A/1hSznTYqI1TSekRT4wvb2d3DkxAHvzS5uVtf X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: e345eb4a-0602-46ab-5d02-08dab813f019 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Oct 2022 12:08:19.9222 (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: /oAG1Zxrur83g/REySxiLvWRKK2j5BWRkCymbphsYAMqYz/tBfUnzy5kw37B7p/Hc6faKl3eeSs5jTbBZuWjqQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4468 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747843371664299962?= X-GMAIL-MSGID: =?utf-8?q?1747843371664299962?= Need to stop the flush thread running externally, so export it. Signed-off-by: Yangtao Li --- fs/f2fs/f2fs.h | 1 + fs/f2fs/segment.c | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h index b467c0ca1118..0d072b029187 100644 --- a/fs/f2fs/f2fs.h +++ b/fs/f2fs/f2fs.h @@ -3732,6 +3732,7 @@ unsigned int f2fs_usable_segs_in_sec(struct f2fs_sb_info *sbi, unsigned int segno); unsigned int f2fs_usable_blks_in_seg(struct f2fs_sb_info *sbi, unsigned int segno); +void f2fs_stop_flush_thread(struct f2fs_sb_info *sbi); #define DEF_FRAGMENT_SIZE 4 #define MIN_FRAGMENT_SIZE 1 diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c index 282616e6852a..f0f52979397e 100644 --- a/fs/f2fs/segment.c +++ b/fs/f2fs/segment.c @@ -671,7 +671,7 @@ int f2fs_create_flush_cmd_control(struct f2fs_sb_info *sbi) return 0; } -void f2fs_destroy_flush_cmd_control(struct f2fs_sb_info *sbi, bool free) +void f2fs_stop_flush_thread(struct f2fs_sb_info *sbi) { struct flush_cmd_control *fcc = SM_I(sbi)->fcc_info; @@ -681,6 +681,13 @@ void f2fs_destroy_flush_cmd_control(struct f2fs_sb_info *sbi, bool free) fcc->f2fs_issue_flush = NULL; kthread_stop(flush_thread); } +} + +void f2fs_destroy_flush_cmd_control(struct f2fs_sb_info *sbi, bool free) +{ + struct flush_cmd_control *fcc = SM_I(sbi)->fcc_info; + + f2fs_stop_flush_thread(sbi); if (free) { kfree(fcc); SM_I(sbi)->fcc_info = NULL; From patchwork Thu Oct 27 12:08:07 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?5p2O5oms6Z+s?= X-Patchwork-Id: 11759 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp198424wru; Thu, 27 Oct 2022 05:24:01 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6dKOCvflbJd38hemU09uGQBFO7E2N0Ms0oC2Q20ZbAhjnTdwLJ5OJ+a54ONTjqgI+nh9uh X-Received: by 2002:a63:1a65:0:b0:460:d5db:8688 with SMTP id a37-20020a631a65000000b00460d5db8688mr41772278pgm.221.1666873441507; Thu, 27 Oct 2022 05:24:01 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1666873441; cv=pass; d=google.com; s=arc-20160816; b=zDhb4oBwGkZC1ESVqkslnql3pXEXQ7U2g+/gxOw3j90KSFTvVQPhUj4rkhn7RLQS4O VukbscU6KES6nXUjjiuwg7l93ERRLjOdHeytCOcQwc2A8T3pxKcX2KewbbaaS88tAr5W NHLr1BLXnoV4J5hLbC8eWz99WKTVI0iqN2Z/i+miQ5hnfFjfPlRWAX8hx+mWd/oJK+W2 A5ajv9uRuA0Wp77h3W4ISBbwueKJbKSuxYYpq2UJnzCAOoxoRMd2oe9L9blz8Y8nRGcl TlbzTDFhlBWqU7YhbggrzOpE9Q1PPo86wFqwBKSQ0bbuBjgNEWfrkdIRtmcQ6GkGNQCx AVeQ== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=2BXG8Fp97L6EsHvAXor2ZVALxWwWblT4dH7op06AhfQ=; b=MkNRPRU0geNU9TV0VARaO3nq3b+/gqTk+4KgE2PjpK6mpGNKvrXqKI385wIkkDoJSx GGcW5NLXdY8dVif5Nz43PRUUPGGD5/SFqBNqeovdkKVzLs/Qv9H4ac2v2Ew8oUBfl7a1 S1yHF0A0J1B4gh6DycBRw1bpHhZqqcN7yEqXv9055vBVN3+v2XS5UTAtqXPZsSooAYKK J0sFTjayXxfgdfZ1C2ror74vfc6pJ9aFK1GmFiNkKUVxXofxQjWbMvJysGkK73s66wfI R+pqccV/L0TGwbHI63eSr4fVpx15/0thp3a7SLflgVNNQUrjqRsbU3BUdjJCVQ9YfnyI X3LA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b="PCk/cZIm"; 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 n10-20020a170902f60a00b001868375410dsi1516452plg.64.2022.10.27.05.23.48; Thu, 27 Oct 2022 05:24:01 -0700 (PDT) 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="PCk/cZIm"; 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 S235573AbiJ0MId (ORCPT + 99 others); Thu, 27 Oct 2022 08:08:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59902 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235563AbiJ0MIY (ORCPT ); Thu, 27 Oct 2022 08:08:24 -0400 Received: from APC01-SG2-obe.outbound.protection.outlook.com (mail-sgaapc01on2125.outbound.protection.outlook.com [40.107.215.125]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5A7D5DCE80 for ; Thu, 27 Oct 2022 05:08:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hMtRq0ZJU7tsgcm4mR+v9IIIo9kXrabIT1QxfoIGxMUhqODEPaIeo5BfRUa+GjsXQWzQqdNxCUY72Tsrjcl8s9tJJqUVl/RXKZxwV6Z1XCggStmjIblv7/n56+ua1VgPTsk8GzAJ2mwXAz3XobgLn518U+dLy5f0VGWisHi2Si6lEDfNu+UjgwVtH2e6X6Exp0sWkOXxE/CfHrKFCrX4Cn8crUA4R91uHrSpuINyze+790oY4DsT5LN5mJlrB/lveZdGq5i2NEDreK3AxRcbfsx76hzI9ZOx92Wydm1qvofikQkc/P9hlIXJWCQemQEvL26GsIfnvQylup6bGU3uxg== 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=2BXG8Fp97L6EsHvAXor2ZVALxWwWblT4dH7op06AhfQ=; b=AAJnpTuRNPXyNSo5zuVldXDSMI1jvtSVIcv0mTmxl1RBUO3DC6eFX4m3Y0tsQEeY+gT0dCIRTA4RJuGnWK7A+ssv+dcbwsISN0LaduYhCh8o4lu1w+dIbPkBMzpqukaX6I+ca8udyubyE8yocw4seOQYjaZgLLPK8DtAOWtUj28kxV6fWefJrQutLQiS/3GFnS81RXz0IkS/dy3ndpf22HizCe3R6Epp0HMNeSEiEMzRxA4hPOCajUB/fNDx76XIy47ACuEscH+g4Qs+dqndUUNZaCYOyeG3Fteks3D0Rhk2fSE75Z3WFPqaMK6cI4RJ9CNJP8FNwq0lA20GQ7e7nw== 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=2BXG8Fp97L6EsHvAXor2ZVALxWwWblT4dH7op06AhfQ=; b=PCk/cZImjbtP3lU2EIc7XJK4CsyJFBG9IiIv1BsIHBAd9i56lmnbWvqm44R6wAPz+VAMZqnVy4VgWE0m1bA/PMvZh8ETFWY+fRajSdNASO9nnmdlW1vE1JBOiEeVwnBouRsEbxwVyXw/N0QU9eAB4cCpRoLBvn/lrPSX2Yvpy6v5cLwuvrOdxinQubTMa37DmT33dJxO6Kjt533k7QjjYZ2hAG5MD9hKEFg+KcLIjt7R3rkTcpdNF9wakaqSGsr0UVh+Cya1VSHRPRpGBrO9sroNiCX2WN505PRs6Bv8SFvyPWt3GcrLxtEfOv00Kg2fzb021rQh+NQMvFCc0zBf5w== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) by KL1PR0601MB4468.apcprd06.prod.outlook.com (2603:1096:820:73::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5746.28; Thu, 27 Oct 2022 12:08:21 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::c84b:5a6c:d66f:c0fd]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::c84b:5a6c:d66f:c0fd%3]) with mapi id 15.20.5746.023; Thu, 27 Oct 2022 12:08:21 +0000 From: Yangtao Li To: jaegeuk@kernel.org, chao@kernel.org Cc: linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 3/3] f2fs: fix to f2fs_handle_critical_error when errors=remount-ro Date: Thu, 27 Oct 2022 20:08:07 +0800 Message-Id: <20221027120807.6337-3-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221027120807.6337-1-frank.li@vivo.com> References: <20221027120807.6337-1-frank.li@vivo.com> X-ClientProxiedBy: SG2PR01CA0187.apcprd01.prod.exchangelabs.com (2603:1096:4:189::12) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4468:EE_ X-MS-Office365-Filtering-Correlation-Id: 037dc5a4-6192-4f99-7af1-08dab813f118 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: tC9Hroagrlvp5OYzDb51PDnJ+90dX4w8hc/UCsXzwUcukok+LS7DfZAKWYMEH7ptG6IcND3pc2pFDwPHOWBTGF9AYSxbrhnLKPrpw86307CV5mq3q09i1bZfGrm+jKpWVUMAIz7asDHoXbRUhpC+YQFkT9sa7lGHBgOY3DTzc3F/94nVg0F7HSyXVUeZQgP/b6h1fVp6l53Uct+Z9KhMHGztJgQN+E5zNzqSRTcYByvi7cq48ESBsaH5ni50LF63mGBbXe6XzXF7aiZPoLdgIYWggrJqaxuim+mgwQPabn7C6dEiX6YmfW6xu2pFCQzHDoG8VjJHBaI0M9jJICY90zpudDD0hHXtR1PJC1gZBxv9h75PsBx1uaSPxgfU6bxkoO1fQmBvhgQxDcFci7goDBcgTcr1VPTc+0PsCLbPjMqiCCpJNTzcije+A1Zu9oKb2npwMqya5+CJUTi+EqM60hBwEWAzLU3IZFCssLtjmHZFXc7Ty9YjYz8USn9TsI4r0wdeX6ROXgRAqg8+4YA/5qKPYSjqAJtsXCVTnC8ag3CkzuquXdp5t0viYv9aY9j8kmkVtaVQYNCaHyewWxtEYPlqG1bGBOju+MNm7gg0/QxadxJhFY6uRuY844YfIVzMvGQGPu89cpdxTA9+V2/rGJeNiWnNz2X/PjVJ/su6QStQ7L2T49+9/y7BeoSnRX8D2ub9xB1hsufwSrpGlcUa3jmIt7TQkIdi7WnUKhKUZcxoxlKatQX50P8+tAD31BTWqslmOj2PBFjUyGfOup5xSw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR06MB5269.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(4636009)(346002)(39860400002)(396003)(376002)(366004)(136003)(451199015)(36756003)(186003)(1076003)(6486002)(52116002)(6506007)(6666004)(478600001)(107886003)(2616005)(5660300002)(8936002)(66556008)(4326008)(26005)(38350700002)(38100700002)(316002)(6512007)(4744005)(41300700001)(2906002)(66476007)(8676002)(86362001)(66946007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: o8JA+e06gWdkMLKaROAVxUPg1dhGS97eX00KPEa7XCTe2A2V0EfXQb+KGJQa4yUWVC3qBAyugmIj80lKuVfUSz6fJudlb7v84t/gDKhP3YxUq4vOvF1ObWAX3gbEHwfXRRFgpz81LD8NITQ4NGLKlsJB6ZZCdexeoDgT1zcsUbJO8vO0+ns0iCTaKRe/URUcGKVM/w1cPgSFU1rkR32S9eNxWugnO39/3eqxHI+QFas6x7NDpoI+c7YLon9loZCUgW+nPJ72OXOO+4tt3coyZ8T1b59QPwfw5End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YijRRH4Lpsqj0MaQB1mnvkNwHkDY9QKHJA4h28Fb+W0dFm9Z6mmoNKduNwNG+mg/gugvg4E2JyDhdWlmKfKhewuCYD5z5/hukRIkR79qlgwoBGufgrpEiWoSWxnlTCHBNK9y/ponBF3HQ8jWXLt9pzh78wMPrGlgBFwR5omVr431VdMo8taFpX/GN/BM/mcABDnoosr9/Dw2u0FwCZJLY9qdWvDX3T6Txy6QxW+ X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 037dc5a4-6192-4f99-7af1-08dab813f118 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Oct 2022 12:08:21.6711 (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: VUR49QDZdILOY62IeIja6H/3EcYwTX/q4uLhOAF6zrTK5egMQsHJJ7E4AQ9cBEVY9VDOsHuloqdhEceEHw1gQg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4468 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747843485751637868?= X-GMAIL-MSGID: =?utf-8?q?1747843485751637868?= When a fatal error occurs in the file system and it is remounted to ro mode, the flush thread needs to be stopped. Fixes: d81ab30e85a5 ("f2fs: support errors=remount-ro|continue|panic mountoption") Signed-off-by: Yangtao Li --- fs/f2fs/super.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c index fc220b5c5599..3a1238a82dc9 100644 --- a/fs/f2fs/super.c +++ b/fs/f2fs/super.c @@ -4017,6 +4017,7 @@ void f2fs_handle_critical_error(struct f2fs_sb_info *sbi, unsigned char reason, f2fs_stop_gc_thread(sbi); f2fs_stop_discard_thread(sbi); + f2fs_stop_flush_thread(sbi); } static void f2fs_record_error_work(struct work_struct *work)