From patchwork Mon Dec 20 01:52:26 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yuezhang.Mo@sony.com" X-Patchwork-Id: 12686979 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 02638C433F5 for ; Mon, 20 Dec 2021 02:19:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237237AbhLTCTd (ORCPT ); Sun, 19 Dec 2021 21:19:33 -0500 Received: from mx08-001d1705.pphosted.com ([185.183.30.70]:60248 "EHLO mx08-001d1705.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233948AbhLTCTc (ORCPT ); Sun, 19 Dec 2021 21:19:32 -0500 X-Greylist: delayed 1602 seconds by postgrey-1.27 at vger.kernel.org; Sun, 19 Dec 2021 21:19:31 EST Received: from pps.filterd (m0209319.ppops.net [127.0.0.1]) by mx08-001d1705.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 1BJNBbr3008278; Mon, 20 Dec 2021 01:52:32 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sony.com; h=from : to : cc : subject : date : message-id : content-type : mime-version; s=S1; bh=ggSg3gyoYYVUgycNDTP693GiZVciaQwaoWZXodHYcUY=; b=VJVfQ2HWcrH3nk+gACug4NrnU7sls9ar9uS3xfYII4TpWUCJd433KSjZWCn2vxGXffKe /AvPQWR2CrdR1cVNOu37/JzjoLL0OSKCvm95MO49ROaRHFvGwKJtpS/nHxbLos+C24HR xVX7YS1QRB63rr7sj9QMAqzQIaAr0FTpgdAEri8wEyxyw6nSYPG/LrDquc5EQkHkdC/s ApheIPAzQukS4v+NoscBovkn6oN4x+bQr3jqGA1lSxDLXYIYtbOrBBnmSSVeXrnoMrzj AJbjHi3bYchxqmQfxeJLE2cTGHsRawNhTtRi1O+8EbaZlhT386RfhNSUmFFX7e2OXiLh 5A== Received: from apc01-hk2-obe.outbound.protection.outlook.com (mail-hk2apc01lp2050.outbound.protection.outlook.com [104.47.124.50]) by mx08-001d1705.pphosted.com with ESMTP id 3d181s1ef8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 20 Dec 2021 01:52:32 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DI32Cv7zqU5EJk9AIi6KinTKEZ67icvgB4Xe4f/ajLzqavgNwwOLKNw6w8IGsJtiX5qP4f6leyQTSXKTtZbZY5O+N2oDFc5RhebZpRbuXxr8nrB7Kn/QRy5Ft4YGKv2y/O9KXJ/uYTu1uH18SNpkSjB0wYjZvoD8WulD+kekPNP9LUc7UAFdCfsz0Te9d0M7vFXf/msgo3ztntxsusM9FWpCK/8FsTlX0jW7huQhtbQa5BoeZ0IkVpPZqc0k/FdcZaBpyfJcRi+PU3wGKWbMuc11BcFR0V71tAzctnsg3YuLKRz8SHZRbH2EUK7t9MjL3E7PrJXLCwZn9c+X0BStWA== 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=ggSg3gyoYYVUgycNDTP693GiZVciaQwaoWZXodHYcUY=; b=RzfCv6M5bEGIuLwy/MFaZnymerMyrYtFEW/h/gLm+dV+dWQpxrUrh0F1c8ZfXuJHYsNFE8cO8VKQ+4/2fdeGhtetlkUS+IZkn00pezyrr02/58FzEDNPGSFv9IyrUGWV9guTm5oVw/KR57Y6s86bjj7FTFKVw9M9ONI34n3PzBgnRbF/+ghiyltV8q/2kzlgiyJ0F4/BtEHjUTQ/4uOTb2gZFHvyQQJfK4oZDa5fGdvuHOfN/OtmLin5eUu/NffkCak01bZfgebc4GIXbmWlCYZss/KFtv7dKj2SSXwJ1/0iE8JgGh9awdfIRRcw0pjrERQ37s+l9OYz8W6i2x6rSg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=sony.com; dmarc=pass action=none header.from=sony.com; dkim=pass header.d=sony.com; arc=none Received: from HK2PR04MB3891.apcprd04.prod.outlook.com (2603:1096:202:35::13) by HK0PR04MB2786.apcprd04.prod.outlook.com (2603:1096:203:57::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4801.17; Mon, 20 Dec 2021 01:52:26 +0000 Received: from HK2PR04MB3891.apcprd04.prod.outlook.com ([fe80::bc0c:cdfe:4b54:5b9b]) by HK2PR04MB3891.apcprd04.prod.outlook.com ([fe80::bc0c:cdfe:4b54:5b9b%6]) with mapi id 15.20.4801.020; Mon, 20 Dec 2021 01:52:26 +0000 From: To: , CC: , Subject: [PATCH] exfat: fix missing REQ_SYNC in exfat_update_bhs() Thread-Topic: [PATCH] exfat: fix missing REQ_SYNC in exfat_update_bhs() Thread-Index: AQHX9UNv8hzMxe6lo0mPytW04+aTrg== Date: Mon, 20 Dec 2021 01:52:26 +0000 Message-ID: Accept-Language: zh-CN, en-US Content-Language: zh-CN X-MS-Has-Attach: yes X-MS-TNEF-Correlator: suggested_attachment_session_id: efe74ad0-b34f-aa49-e0ec-fd6c98340b19 x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 6a5a5f24-f348-4d62-0b9d-08d9c35b5ff0 x-ms-traffictypediagnostic: HK0PR04MB2786:EE_ x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1468; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: Lrl3Afui5hhwc/YyaxwN76pRw6+wxpvcdLFDQlke2/aAf9QrmssZdY0wXw/7E7+uWiKOJSHgbumO9eL4LBLFkNRom86xSz7jITCYOL1dvjunQ/nC/mgqhFnIJCrsckWn8sCN+C8LeAn8ve5Eyg2IqXKvJXVUqAy28yBY8ooGipQvHvlErwYieIPIx0lVwZwLzG0gaFlPfCR+eg39byjY6d5jrRq9VI5ddNu3zLd8Uzqz9SaWVqicPV/RE7h/BYNBarCpKe/d/743mJ0revCe4emQRkNFngMcINnT5UPa1/KWA692vVpS7fy7ykv7RdpimJwQRbGbKFEQsv+B9JHzBUglr5h9xvn6wkSmFl+UFzoCKZaJ05qi67TsctP4/zsKuSEAOdNGATO/uyEJD7oCekrULF+fsjRaesPmJ+fcEI8IOaSg08iTeNmuyExtvucUD7Va6Mf14ib7MZJqGEvmW6DefObCxG7wt1z63B/F4ll6M1sPXoRKhrxsBmZnA5+kXUGHo8jA/4lkplVxmbNYquPnRYzChHI1r4Qwl+Mtc4h9X56FLNuvk+7pKId+UF0wjNav6I05MpPw6DqZ0KxtGle7Rz4nAYHWslFFfinnBI1NTSvWrMbYQ2ba0cLSDga+qxIZBGlIH67FeDpI+9lvT8sv8LO3yz9Zm2F1u0wxkuUVK7PNHFHyYHwoc3vH+nyo9bLgdQeoANU+h24x/djZ0w== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:HK2PR04MB3891.apcprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(366004)(64756008)(66446008)(52536014)(71200400001)(66946007)(66556008)(122000001)(4744005)(66476007)(76116006)(38100700002)(4326008)(91956017)(38070700005)(5660300002)(9686003)(33656002)(83380400001)(8676002)(99936003)(8936002)(82960400001)(86362001)(316002)(54906003)(2906002)(55016003)(110136005)(186003)(6506007)(508600001)(7696005);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?eucgb2312_cn?b?cXJX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0FobnNo?= =?eucgb2312_cn?b?U1A1aTRGU2RrVWcza3B4WDZIYkdRV2l0SEwycjZFYlJoZ010TXJ6c1pKM291NGlC?= =?eucgb2312_cn?b?b2FQeXQxbm0vYXJzZXdQQUFmNUJSN3YzY3NqLzdXSXM3amNKNm9QcndhaktsTklQ?= =?eucgb2312_cn?b?ckNzblNnNDF0WDdNUCtZdEQ0UnZBYnNJZHI5em0zd2NvanNqSGx4aTJWSERVempQ?= =?eucgb2312_cn?b?Ym5tQUxodFRIZ3dvQWpFNmJRalZGeDgzSkxSODhmNldTcEN6RmRrMloyQmwxRUQy?= =?eucgb2312_cn?b?bC9pellWeWVub0FRRG5jYnVETmMzSzZDM3U3OStGbjZIeWZQMnVRYlpHcTV2eUNt?= =?eucgb2312_cn?b?Y0FHczFlZ1ovRTlJN0J3cjRSM3F4d1M3alo4TjVpSmwrajJ6a3Q2SU1wandzNzRp?= =?eucgb2312_cn?b?SnhQY0pkM3BSZ1Uxbkswdm0xdVU1cXhQVVFjY1VKM282clF5N0hvTElnSkNnWmpj?= =?eucgb2312_cn?b?MjA5S28vZ25BNXIwd0JZUmdMaU4xaVJ6M3FqSHlyRDVWZENVUXlRQkU9?= MIME-Version: 1.0 X-OriginatorOrg: sony.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: HK2PR04MB3891.apcprd04.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6a5a5f24-f348-4d62-0b9d-08d9c35b5ff0 X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Dec 2021 01:52:26.7705 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 66c65d8a-9158-4521-a2d8-664963db48e4 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: xieqHBNHllIVYmguq6K0HjI7Ti7ijO8ISYBDCnxaOxQ+Hp6jJx8fuIoVvz/VvZve7dBb8vvdcRWnMmI5Ek3Cew== X-MS-Exchange-Transport-CrossTenantHeadersStamped: HK0PR04MB2786 X-Proofpoint-GUID: uzikrdRXsgS-YfIQsbMtXDXhP1IFL9D1 X-Proofpoint-ORIG-GUID: uzikrdRXsgS-YfIQsbMtXDXhP1IFL9D1 X-Sony-Outbound-GUID: uzikrdRXsgS-YfIQsbMtXDXhP1IFL9D1 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.11.62.513 definitions=2021-12-19_07,2021-12-16_01,2021-12-02_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 bulkscore=0 suspectscore=0 impostorscore=0 priorityscore=1501 mlxlogscore=999 mlxscore=0 spamscore=0 malwarescore=0 lowpriorityscore=0 phishscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2110150000 definitions=main-2112200009 Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org If 'dirsync' is enabled, all directory updates within the filesystem should be done synchronously. exfat_update_bh() does as this, but exfat_update_bhs() does not. Signed-off-by: Yuezhang.Mo Reviewed-by: Andy.Wu Reviewed-by: Aoyama, Wataru Reviewed-by: Kobayashi, Kento Reviewed-by: Sungjong Seo --- fs/exfat/misc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) From 6760187314aae4381ff573bd78a0153a6b831e0e Mon Sep 17 00:00:00 2001 From: "Yuezhang.Mo" Date: Mon, 16 Aug 2021 11:30:51 +0800 Subject: [PATCH] exfat: fix missing REQ_SYNC in exfat_update_bhs() If 'dirsync' is enabled, all directory updates within the filesystem should be done synchronously. exfat_update_bh() does as this, but exfat_update_bhs() does not. Signed-off-by: Yuezhang.Mo Reviewed-by: Andy.Wu Reviewed-by: Aoyama, Wataru Reviewed-by: Kobayashi, Kento --- fs/exfat/misc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/exfat/misc.c b/fs/exfat/misc.c index d34e6193258d..d5bd8e6d9741 100644 --- a/fs/exfat/misc.c +++ b/fs/exfat/misc.c @@ -10,6 +10,7 @@ #include #include #include +#include #include "exfat_raw.h" #include "exfat_fs.h" @@ -180,7 +181,7 @@ int exfat_update_bhs(struct buffer_head **bhs, int nr_bhs, int sync) set_buffer_uptodate(bhs[i]); mark_buffer_dirty(bhs[i]); if (sync) - write_dirty_buffer(bhs[i], 0); + write_dirty_buffer(bhs[i], REQ_SYNC); } for (i = 0; i < nr_bhs && sync; i++) { -- 2.25.1