From patchwork Fri Mar 10 03:08:19 2023 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: 67192 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp659015wrd; Thu, 9 Mar 2023 19:17:33 -0800 (PST) X-Google-Smtp-Source: AK7set/mqYpnnx9BC/osPVyLEXiu8W4Z63x9Eih2wCl74Tt7L3ysyuAeRy1PL4iAt47C5D2EaLzR X-Received: by 2002:a17:90b:1e4b:b0:237:94a2:b531 with SMTP id pi11-20020a17090b1e4b00b0023794a2b531mr25285001pjb.2.1678418253005; Thu, 09 Mar 2023 19:17:33 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1678418252; cv=pass; d=google.com; s=arc-20160816; b=kiTaoUtyiMa5kA3qdA6Dy/i/8pEdvbFMNd+l0esK1ytzxii7Vc1BC96rPt7/t6Km1g owWKeBS5gL7t5p375fArSssZBkvSK9PhdqrtVVJUCx0B3RD2KbO0PEMc4gJV9QoY0FrM aAMvhScy/Ah1UCj3M7tkQvUwQNa0LqEZGls1jZy8/scUd7DR7KU2vPNH+ZlE+S/9MMvt yPKCnVSpkNCNfzJVNI9Ht3aJqFVst3VVHqeJjt1HDjAxO7fKtpWTcx6mnfZwA/526fOr cycwHyh3A/U04KSiMmesT/9LLqrcaSmhm3eu2mwHBqnYJaC6e8+Qv38ivwK/q32ET/Mw LuvQ== 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=SapfSKyA5hjeA9Tpi9nggPtAuZODvYJOSu/24Rc8dH8=; b=eq/l5geSQoyOWeGxv/32J+p2WwRV1bE8aLYTcvk4k+iecoaaw+E5b8d1ynUbv9NU0R MH6h/XTjWHkhKAix/+ZGVUCn05HGLX6ivDMHxDqPE/f6k2G74uZ7xpslrp0aJn6s6Ph0 1EETfFVvFnkRiRTrdD5+H73JZZ/0J+bh4X0I1GFJiaXkUQz1sF1io5FE6coVPl6S6OpB +b4JHb0z8W8mAijAO5SF6MP/M8xS/pLkK8zkToJeFNdVQxemtugYsNtIsUddla1X6bDq 2hi9gJfJ3aYVY9Pml7+9CEiCvapksiuGSFnhf6xkNVJKUs+4ed8cwFC/VWvPJ++QH2pK 2hPg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=qeZWkIKG; 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 ay6-20020a17090b030600b00233bafad308si1332105pjb.150.2023.03.09.19.17.20; Thu, 09 Mar 2023 19:17:32 -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=qeZWkIKG; 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 S229977AbjCJDIr (ORCPT + 99 others); Thu, 9 Mar 2023 22:08:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58842 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229754AbjCJDIo (ORCPT ); Thu, 9 Mar 2023 22:08:44 -0500 Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2095.outbound.protection.outlook.com [40.107.117.95]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 95B5DE1931 for ; Thu, 9 Mar 2023 19:08:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=h/q/ber3wIdI4G/AAgqk7EyokhVxLA5yFtKJfBXfV4CHCDH6mCzWpklZFjw+YwDIraPCRW0KHVaz4A2+wmaDtfEkTGWYq1kmWVdZEOoHU5jAnrqV7GpFCiQYdtaNvk45f14bpcsEBrdx4gEo9gN1QfKWcKjoY9qnrUG0Bz05XDTa9uzzHnLe+yc3aN6j1GeXUU95B2PBEIlHHez7aimR5PhygZvt0RyI8j0334G0Tg34A9vpr3JlQm4PaPHKtcfo/YMtSl9AHkoUh9VgoKazrvPk6wUl6xiYLVMO1cJyI/8JrvE+8sUpg/lpAr1wwkQanXDUdWFi+WOo2DquslseFw== 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=SapfSKyA5hjeA9Tpi9nggPtAuZODvYJOSu/24Rc8dH8=; b=dy8XVRCXqhvKtYClvhtdLTayabXPgMQbI6F6ToZRxTLSm+twlNYPpAZ1DyWzb7Ff5/ESqKddoxppHmjTpAzzQW43vWl3OBXCcIVBKRHspBl27MJ2LI1jRGDxQf8RHhgLlPxJai1DE55XaewlZI0zPxO9ntClGK/xsY75KGKlCte7ES9CzlzeJ4ywfJDmoN0n4Y1BjOuy2Yh8KFXlB4NrdbV7iVxYzyFWbTdtxtrbgkbizQuHf/U5QbTnGnSUZiYSIyabL+ClcYzrYw56Sd4ZY8iaR1clN110G0tMJUbTF3M1Fj+dK3qAOTi7g69eF6mCwjs9Ui9eBq/n8Gak4CPQAw== 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=SapfSKyA5hjeA9Tpi9nggPtAuZODvYJOSu/24Rc8dH8=; b=qeZWkIKGnA/aY6Q1YywNWXsBVNLkQbgxh7emPFc/1Wa4OP7kuzm9/8IQiEAmqeal9CLHMBf0BI5NnoLgbL6sK3Z9XjxDNZ89/Ucngz7Pk8wN8Zw0LkL+jrqJXgXkx+sM57CLTa57bRJyIKyqJoXAuCz2mPRbj6Dt+lFar7lbW25OoW62sW1FDT9jRBEyJSuWRtOqAGwRNmBlZSg+S2LhlWndOVAqWfaF2c4VnNSgMU193CNo9GEs2mAH+TsnhNetoCayaikQCqG3s4DbBTH+VA9wOzWIWRHhBT7Cg3QsbPMI/6xa2WSH8eK/5eukeyctoLozkSREIbDTJJDnXybbcg== 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 KL1PR0601MB4275.apcprd06.prod.outlook.com (2603:1096:820:73::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.19; Fri, 10 Mar 2023 03:08:33 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::daf6:5ebb:a93f:1869]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::daf6:5ebb:a93f:1869%9]) with mapi id 15.20.6178.019; Fri, 10 Mar 2023 03:08:33 +0000 From: Yangtao Li To: almaz.alexandrovich@paragon-software.com, jack@suse.com, dushistov@mail.ru, brauner@kernel.org, ntfs3@lists.linux.dev Cc: linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 1/3] fs/ntfs3: use wrapper i_blocksize() in ntfs_zero_range() Date: Fri, 10 Mar 2023 11:08:19 +0800 Message-Id: <20230310030821.66090-1-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 X-ClientProxiedBy: SI2PR02CA0026.apcprd02.prod.outlook.com (2603:1096:4:195::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4275:EE_ X-MS-Office365-Filtering-Correlation-Id: 2094acc3-f270-4212-97f6-08db2114bb9a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: hCUfcQxErox8Tyrpq6N62DFDvoXUJKgLaqAkQciRoRmVcXgKvUpe4Q/WSLboCEapJs+bOkj2JmOXmaqsTY6XNKDZz5HvTEaE9uulEhR66xi7KjIYvAJYs4kYg3nZgcGZIns9YYQaDYtwoGsIFjEJYaDXcJJW7LipypFigT3CeroY7f3n8aPY4sczBDoUVP3Sbz/uw/2odG0D+wCTMZS+ttcpUvxia9+Vq7o6nfzlVUNlRendrUxSZ/D/flBg85gHMCo8Drvhm2fCXY449Jb/x6RllaaTRfi8/hv14NijMLjS6O4hcgGxJktsZb9d99o9pac6bp7T5b5MlNVsKdsuYiYxCZOPdBlXWwDNtiHWgHHYwxdO4BYlzEGo3ULTAVd/vuavr2n9dxg3iGqCscCIrwfEwww4D149qIKRw0751JhA1hTk7ayzBodEJ3WoLaFMtw/AnmHWujODdvHtuZo8OIgM3L3yj4kDEfvrmk3OSrEmKpyplCHFqjQJ3LdA0e3HcYA+UDvkrAzKMRTiIH7S4eBq0wLuW0+f6adLom6BIJmvefE4Q8niLDiFlMePlKKUeWOMMnes9zacUp3f/I7/s4XNde4UoGIMNq+z4r0zBWA6riBX6jjJXk9ngfk6J9/3MVVY6R+vW9Hs6oXykhq6RrkGr07D0wx8hTqYOitABufrR1wZhd3h7jZ3vnniLnUAt4matyAY3DKhH+dX4gGeVg== 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:(13230025)(4636009)(376002)(136003)(346002)(39860400002)(366004)(396003)(451199018)(36756003)(5660300002)(83380400001)(107886003)(6666004)(26005)(6486002)(1076003)(2616005)(52116002)(6506007)(6512007)(478600001)(316002)(4326008)(66946007)(66476007)(8676002)(8936002)(41300700001)(66556008)(86362001)(186003)(38350700002)(38100700002)(2906002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Bjiue+JRBlzWhuqnjm8kfq4oaJnWJrC4q8hYVF69bcbWwUhTkgIX5U637sFdSRMINsU0f4DNy4CbTeON6Qgzc9m9HMoMmt67K9+dQ1gU/IeG0xBdIlJjyqAalBJU8bN48PZc5O8fsyundsnj1jSL2z4oBNXHf9QuE5Mz9Dz0fQTor6aJ/D2DHIcYYPfN5JWt+Yit634F0hocgwqR1aokFLqBQDkMBHpOXGlVd6gUlQwhFdQ22P+ICoVL5iMkGbaInWUFJczIY0UpElwykTOMiO2iu4l70EyzUjY9NNGVCFEmCI2btw8S/8mrbISkZE9lmshlQvnUMjQV2uDU8ET7ltdl3rbcfAs0Fr2/GpPsg94n1ceKdGcx+YeKf36cwhziAWGdmhRA/4LcbjbONc/Q7KHDnQin2F+EQdjI/9E5vLQ5SrUZXqMyVKEfsQbRp73B+9CMWEFAzDNmFpeKxI7lceAtTrosPIGhN/nZAWmSUCYbIeJ8eggt02jg1J0jJhoJwgG3TL+lHnssCRYpnJ/aVyCTeTg1KWpNw13X7aSULzt46rVJStD9vniXWWXv3e5c6AEZSLYVZFcIB9bAnc3UG1tmDUAiZJfa33lZCz4Z2+6C8f0wYQlumTh3uN52u7zmdT2vToW7KtMmqhgIpHiPElfhQIKXYjYb3mEYOgifKGf+n5VFu+SU5irZLj7JXmFUWx2FGgs/gMwakQX987c+jSZegGFgrU1uZaBsV+bZGfbS/tTmXLvqozQVzZtAtnlKlNDg+IrWf9oTE2KCz/bL9ugTL8wMsyguRkvsm5nlf8o0b3SBI2RxXIAF/bF2buy7TFQ9PqyzDb1+UNkTKUmdJf6/nKwfpuDy0V0MvKFiIJ1hPhSAMuUYScKfKSAGNcZFwiMRDXPHUmKhg15+s2Cg//OvWt/7Xpul070HNCrsYeRvg58w8JQ16pH1yPQmbKLddSVF0xPcebvfQka0I0xu8l+ESfyWDpfO0If5iaFt8xWaJVju3mWGTefp40kPrgQ/g02HKwLGy8imBXtDpoSPGMx42yCL0B1ovkYqlQKhMLGEzxfb3cnIBUb+5Uua5VXYu/H9i9BFG58PpkvGAmnLBZdOBNQf+VvrZ/v6Pe6jBb0pNL8oJXL67NWVIMnE1Qt6ZnQmV2BuwbCZ7C28/Lt9B4xC0Ey//+1kxtEKrLaT3yl1x7L8fG4IIh0tZAmT5bbOHeB85SBtEIoFM3MYfn3ulRAuPQkjKYHb4yA4393naA8PbmsDVYHwdvHpaMu/DYl6WNTPBvy/x3yWIfwiuy+PN8A3wUw11Nj/Y/kpDXHUxhAqyGbuqGDhMi4PhRBfM13Ja5fktdNvvHxzmagxA5GC2OzditGWvCPb4EmbwaSQ9zPOG5XN5g6bnS3vxjTltG5jI/wWcxnUDU6eIPeCRhHKjIhxgqH/LAosEFZTbw8NLFElFZKRRH8BJ1U9tt0C+jBJJAVDzZKbejQjkkkkpCtFooip0lqGDdNeu5YE9uE5PZBzI7Jv1bacjxNrumIeO5R7UbdD2BYQBa6h17r8WSfOBFpGlnLoaMthcmlrfhT6iknghWYGW0cCTU8aLmI5ddVo X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2094acc3-f270-4212-97f6-08db2114bb9a X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Mar 2023 03:08:33.5601 (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: ZF3qKpFoCdp8Y1cOgTgWMEzpWQyPPerO10Sv6KN8YUqa7+Iujlu0tp5sikcCDD7GXrLiHwF3eKvHCWoWhZtptQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4275 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,URIBL_BLOCKED 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?1759949098090221920?= X-GMAIL-MSGID: =?utf-8?q?1759949098090221920?= Convert to use i_blocksize() for readability. Signed-off-by: Yangtao Li --- fs/ntfs3/file.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/ntfs3/file.c b/fs/ntfs3/file.c index e9bdc1ff08c9..9d6ff29de441 100644 --- a/fs/ntfs3/file.c +++ b/fs/ntfs3/file.c @@ -178,7 +178,7 @@ static int ntfs_zero_range(struct inode *inode, u64 vbo, u64 vbo_to) { int err = 0; struct address_space *mapping = inode->i_mapping; - u32 blocksize = 1 << inode->i_blkbits; + u32 blocksize = i_blocksize(inode); pgoff_t idx = vbo >> PAGE_SHIFT; u32 from = vbo & (PAGE_SIZE - 1); pgoff_t idx_end = (vbo_to + PAGE_SIZE - 1) >> PAGE_SHIFT; @@ -192,7 +192,7 @@ static int ntfs_zero_range(struct inode *inode, u64 vbo, u64 vbo_to) page_off = (loff_t)idx << PAGE_SHIFT; to = (page_off + PAGE_SIZE) > vbo_to ? (vbo_to - page_off) : PAGE_SIZE; - iblock = page_off >> inode->i_blkbits; + iblock = page_off / i_blocksize(inode); page = find_or_create_page(mapping, idx, mapping_gfp_constraint(mapping, From patchwork Fri Mar 10 03:08:20 2023 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: 67190 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp658306wrd; Thu, 9 Mar 2023 19:15:09 -0800 (PST) X-Google-Smtp-Source: AK7set9onxJwWWIO0vW1yCq9mtArKtDHYDsWJibruvubZHKgqbjTj+3YkqrkEsrfLQK1AHfdgJIZ X-Received: by 2002:a05:6a20:728a:b0:ce:c188:68af with SMTP id o10-20020a056a20728a00b000cec18868afmr23332020pzk.17.1678418108747; Thu, 09 Mar 2023 19:15:08 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1678418108; cv=pass; d=google.com; s=arc-20160816; b=nf31Q9tTedbzpwZZxNYTeZ5xJU6DoFjU55mkDtQFpT6r0vnD36Evo0V/odKFveHFix s1Fu3clS9xK4u39caEjm5vSFw6nsdZYNFwuk7VV+LtHiM0Onb1NBVaCCzAKEJjVY5rki BczGtFRMnvkqtgc78auIkZ8/LvCoy920V+8JBYqkB4Fdecyaz7Vtjq7ItvnwZFMdHC13 bcWOrwzL0ssMn5Dj7DWWKQPj3HJSq8O44mRKYMcCLHGb7sn/104AQSAvE05y795+HODf negjo+PClGHdFsD73mCEy4OY9Zapt/ngU33eUmL3sYmAAy5MAFYoCgIpxfpk2chMbeFu WApQ== 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=mpuXT1ik5hM+N9WXxYwTeK78MnjS/swJvr170u+j+pw=; b=BIFMQaUL+5WcNbjQij+wdu4ilntq3vFRBD8AVzfHEG6krOhrM565CD/NyZAT5SKBgH lJDRzednxCzkaYODWfXF96NSOqwwmCEJwq1upvS8wESOHRLrK38HboAVpN4slURd51A3 eeoVou/LrWRNp0y1FURK4k1tBYE6qoY7R8YOyjS5P9RQ0BS/8CtfndchT4zPA1eM4YC5 PDRHKUwuIsCiVyhe19DIrh9rBIEXJLFa/sNTHFj3F5D4MmfvPXbLHG4z03RyAq1QTio/ UnrdyRPsQFPvwUFTs79nKVTQu50DxH6q8uBD8BW8fsUCIagDGVxD8Si4OQsGTSkd0tpV 6Q7w== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=UIJk9LKL; 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 q5-20020a632a05000000b005074d00fc04si808946pgq.556.2023.03.09.19.14.56; Thu, 09 Mar 2023 19:15:08 -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=UIJk9LKL; 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 S229774AbjCJDIo (ORCPT + 99 others); Thu, 9 Mar 2023 22:08:44 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58714 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229612AbjCJDIm (ORCPT ); Thu, 9 Mar 2023 22:08:42 -0500 Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2095.outbound.protection.outlook.com [40.107.117.95]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 92A9CDD37A for ; Thu, 9 Mar 2023 19:08:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Q9z3wkIElx3wFrXWvGhIDIUYvSdX+GCpOb+gLhKAtqpuM5igNKGTzf99gUiNh8HC+KsuY2xA0U/NKLbS1nAt3P+ifc5tUBg8DD/x93pjKAOI52xNM3f3CV3hh4USrVn9LdHjHuhB/THW4S7mlMGMmWXAgBb9ga77vdAA2NrtNtZXln5+EGPp6Qwhvqx4dUFSVOuiT9Xt9ZKIdR380oc9z6dcgA9/qAg++PAAmMEHOrs6V8D1xOyD4oqI4bnq4VP8KiFNNyQQpPMQTEMeiOihYXHmTPtCqAaAtIb8Q5aa/F46fLAI3ZW/JOx0cnNm0etuQci1fHVA3L4b5Y3AOG0PeQ== 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=mpuXT1ik5hM+N9WXxYwTeK78MnjS/swJvr170u+j+pw=; b=D4Git9QLJCaq9snWpOw+eejGNWRshxPIqSxvPh84ZIITz/g5CRSvCEyZ1aBXYmr2OqJDWVnlq11jPDd/12dXbYtwa/PRlyyFB4ykmx8YUzACJVYLeFCquHahb7mGYKwuDmxmB0lcmbj4cDRw/urfuHoMU0cGVzHlFpCAEFusLDeSonX2k/d/dtuyYvxUwJdsoZa4X+HbTyAwhxCHemZAs96tRwThtaLn7jvPqxvMIHzf4J81Q8dSsgt1q6E4F6diEjsdATf+zg9gJhaPlyAppNLC0dagslVIMQcS9QCuTneu7sz5KAHq8ib5xKS+vdHUyeH96usVG1YtQGhXIkyXBw== 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=mpuXT1ik5hM+N9WXxYwTeK78MnjS/swJvr170u+j+pw=; b=UIJk9LKL9zMm2AhTMTUa/bc2l/ooSAQ5uTfsd8SstjPgWhWuHft4CHDKCJXWMtHkitfvlE4bBI0iI42IWWI/H7ZNnM6Ruf+wSZklx4lpwswNtdzIhPwOGgeZssle6pG2GZDWVbFooqD2hqlYo+X0pslnQTYPZ8mz1/JfJMVQWxkQgrdyPupVUzZvvEKr3bUBXdpnQpOGaw8VAT8w4uQlNBK6cxUUAtRPAupKR2LA4olguLxjDdZ33e1jKxqWawhVQmtQG0uJ7+xTDRh8fKD7bQ8rVAgvVT/69LsNHwnvq8ccWVc/xRfL5KlGHdAmhxohuVEtr1+Q1LAuOORc3mzgvA== 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 KL1PR0601MB4275.apcprd06.prod.outlook.com (2603:1096:820:73::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.19; Fri, 10 Mar 2023 03:08:36 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::daf6:5ebb:a93f:1869]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::daf6:5ebb:a93f:1869%9]) with mapi id 15.20.6178.019; Fri, 10 Mar 2023 03:08:36 +0000 From: Yangtao Li To: almaz.alexandrovich@paragon-software.com, jack@suse.com, dushistov@mail.ru, brauner@kernel.org, ntfs3@lists.linux.dev Cc: linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 2/3] udf: use wrapper i_blocksize() in udf_discard_prealloc() Date: Fri, 10 Mar 2023 11:08:20 +0800 Message-Id: <20230310030821.66090-2-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20230310030821.66090-1-frank.li@vivo.com> References: <20230310030821.66090-1-frank.li@vivo.com> X-ClientProxiedBy: SI2PR02CA0026.apcprd02.prod.outlook.com (2603:1096:4:195::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4275:EE_ X-MS-Office365-Filtering-Correlation-Id: 37d3bb09-82d6-4e5d-42f9-08db2114bd1a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: wKbXx5Zcr7mJN27dtamiZ1keGus/fHvD5q3Q1Cei9YEEd627AsU9HlYyfnAmoPkFuswoRHKD7cDXnXT/HYNDmExb59V/C/ajgprCJg3ckJxFiZrvoWJehymOcjPeHvRZPSMxxbnm+EEB6ZpXRMLs7MS21TUtWuM5msG55C0WUsT6IY5xABcAU5GIxMoggyIK6ZOaZtB8Sg1vHJFAOVjhDBntQnGn5185WhCJtzFCORvxpe5Uw5JHfGOc/Pod4QTqBPyhLMuz40p1+4D6kyO8JgVd4vexkh2rf4cNnEV3edaN1np0AJI/DRykhlOVezyEpWNB9GQ9b+T+djwyapOmeNgHoEF999Gm0B+oCiKaQUx25atRZ3Db3/WmO1KiiBTxlgnqkJYnmjLGVYoL9GQ6Cu0OJAi0Rd8Rk9CSbw3YmfqyhdbBiC7bAJtK4OVqtzMqcnosSUY7m0i29QaY8Ercp06xKnhZO5jK/FyV02BSjB87ATdsiYQyp0jJ0bDKUTk420oAM5cGx2WVrSSAwwzbj4fLdrsi08JtMLSnp2gjrv+vu/vP8DBDQBcohqEghzKHyhM8DX3uuYbi6GQUjC8ALPLp7tF4WN3LAhxDtQRawv2+5AybMIuHSIFdR+o1ijcxsxtix8CtyshmxFx1yw/XLm7Ca16hsb9fRHLAOPK2+9rK3Wmj/RpZbyTbf0jbGGU/MWBKOakOJolkTa/LBZxGSg== 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:(13230025)(4636009)(376002)(136003)(346002)(39860400002)(366004)(396003)(451199018)(4744005)(36756003)(5660300002)(83380400001)(107886003)(6666004)(26005)(6486002)(1076003)(2616005)(52116002)(6506007)(6512007)(478600001)(316002)(4326008)(66946007)(66476007)(8676002)(8936002)(41300700001)(66556008)(86362001)(186003)(38350700002)(38100700002)(2906002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 8FPwq2CiB/Z9gdRKl+DlbHRyOYW6EWQwjvvm4AwxE/qk7yJivjINAQIr9mmLjYTDbfRnQWfAuYS2VvP/R1iTtG4bi1/R+a/O2Q3PNeed7LJENtX7JUzH0WH7bGzTHOvs34qbWmLfBUbBihmXIcicSLMl0Bm3JrTT5InTWywHX8p8zgC8hnllTEsTPqJ3su5kXlLfnseN0BpVwkapx6UX2mqy9/C5NUgvnZowZ+bKYdGJN+91NrJhuALwg1aM2knhmUQHftgMIGynGBX10nJt9NfdWbLYj4TS6EqWAn7HYsYHq/YF/YNqll63FCeRl7nIuXsyCAxC6D/yc4DQ1HmgqIFVU0Lr6C8fpN6/hAMXPkm1+9ZU0exvTzbGNJQ6ovSmLGa9eFOMtVJ2mSqsnFYpi6npB5hzd6amC4jf54NqtjSWW/ymhEMa3/t3zox00Rna6EKz+wXObyAvI0XTPOA1rDhhg4e4AXmGosnSeZNjph7KEypky6gfOzo86c6uw96GfGon8VUERy5+M0HEb+XaOEHAg46nhJwMOs24ykJHO7gRDobcGnknjbyrzYzzyp1dcl70vZr7VRFrZzZ7OsXtP7dQty1UPsBPebeGGk8rHU3DvOZfW30h24C4ZrJDvkoluDljVT1OqGLJnxQhCtEBWWzco3+QWcyVhaKqUr6jbnpLsGt3nAL2liwMOWNWT2psAUGk0RzzPLT/MGV3Z2Y08WyJGELNvIqSxR4WTgFsKiBnXhh64HErnVi06bMtv0a9qlkuvXa5s1DK5Vibylt2WbAok4qmbQIDr2wGdi3oYJ6hgwSxrg3OW1aakJCmTee/2wiRNoitIoAMPMJ2QaD1t0rr9L6sRytTUDLKaYNuFYNavdEaFXB6016iaaWdadioqxtUPvQo6gopyf68DuHoFOWqOhX8SRDaY6d3aeQQZJvwmmL9QA42RT3rhfSF7MlElwGax+GgOfushGuWgKR+Ht8FFkIxCSzw78WrSM2oZNk2zIPueIuv9q5UuPVpGt9QXZd47v70w9xhdnDs3tXQUBE1A0k41abjQBUo5fpuq0t95lKuZpz/yeYD8Y7cN6VqcK2qcrgmqmvbUwsE32BbMyNqYdRBDq46pFSR0wSNRHc4MfMsHTHMdmuvr6qayHbdtPNnA+YPUVCHhhKeHOyDVzNcBaZB5M7SKnsDP1HMVaVlw58W2OV+7g5f3kxeaOjo6+yy0Eol8yGxpJK2jZ4/JNbIx44xCw6+w2k4GxzL+r/ofBSsQb1AMYUIoWibfW/QpeJrP5x02XlXaKACUefuFem1QZ2dmRiA2tH4e8RP33yzboTcgblzI/dcCooGQkxVXdhxqlxUrUVF4g1bsDxydenYe+daukUmlOdTtD96gOMjZ0i06coKXk5m8ifiVigvFuv2Rg0IyUHmTHC7jeGeI+xNK+gpgENspa84Icz2VXtU3x2eiGQqNlSmFlwUmJC40pSLyg8/qWbNxU5bvkFQEOQHgdoVrL7sCV5PRe9lOhLbAhGk21yeHtOgoafio99b7XnuGdAzA77Bz1BtVc4FEbK/80kTjRn2YCvzDbcrFM6an1kNkTj0qLMR5LQDG1LD X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 37d3bb09-82d6-4e5d-42f9-08db2114bd1a X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Mar 2023 03:08:36.1390 (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: Xx6N4k19eqFGLs5EP2n8fIbjOAs6cSlmzxFV/31OLsW+zLxaJuYJPpFW7xHMRdoRq8+QvkCJTbolzPtbSzK3og== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4275 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,URIBL_BLOCKED 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?1759948946608232981?= X-GMAIL-MSGID: =?utf-8?q?1759948946608232981?= Convert to use i_blocksize() for readability. Signed-off-by: Yangtao Li --- fs/udf/truncate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/udf/truncate.c b/fs/udf/truncate.c index 871856c69df5..2e7ba234bab8 100644 --- a/fs/udf/truncate.c +++ b/fs/udf/truncate.c @@ -127,7 +127,7 @@ void udf_discard_prealloc(struct inode *inode) uint64_t lbcount = 0; int8_t etype = -1; struct udf_inode_info *iinfo = UDF_I(inode); - int bsize = 1 << inode->i_blkbits; + int bsize = i_blocksize(inode); if (iinfo->i_alloc_type == ICBTAG_FLAG_AD_IN_ICB || ALIGN(inode->i_size, bsize) == ALIGN(iinfo->i_lenExtents, bsize)) @@ -149,7 +149,7 @@ void udf_discard_prealloc(struct inode *inode) lbcount -= elen; udf_delete_aext(inode, prev_epos); udf_free_blocks(inode->i_sb, inode, &eloc, 0, - DIV_ROUND_UP(elen, 1 << inode->i_blkbits)); + DIV_ROUND_UP(elen, bsize)); } /* This inode entry is in-memory only and thus we don't have to mark * the inode dirty */ From patchwork Fri Mar 10 03:08:21 2023 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: 67189 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp658305wrd; Thu, 9 Mar 2023 19:15:08 -0800 (PST) X-Google-Smtp-Source: AK7set9RpFYqTflxbsa+LFA7VT5hGyDN6vIuOPx0MaohGs8PSJuX7Ko4cwxMlwt8hAruXwbR+VEX X-Received: by 2002:a17:902:da90:b0:19c:e405:4446 with SMTP id j16-20020a170902da9000b0019ce4054446mr28234794plx.30.1678418108694; Thu, 09 Mar 2023 19:15:08 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1678418108; cv=pass; d=google.com; s=arc-20160816; b=sPxuzTQCR+OR/5GCFFYdshLjRri6fbFqKNGuXPO7v+s6gqJ7QrgdbVlMUxVtEztP7p A60noGsTONLVpNJdYkpkS/4mtBFWYc36/4E4MC7jI5NeSy0LI7ovGZhqrFiXm61gJfvY FbbRcx2gUJEMUy1Z1lSgrQKd/RlPdtzLSjzfljpDauKTuZ7nr7+P+CBHdRDFgRZsC57N ZFu4LJN69YFtIhoj9toZtyFRWpHMseV9f72eKR/6CU8qjLgS5+k1DX/zTzWqfAE6gfl5 EHfibOhZoASbJSZB0KPmSo6LoJGBq4MR8dUwGhoVNBzmPF+6mTJAbczHVTHooeDRUyib 57VQ== 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=17DcBGO+6YLG7OAiYgPiEvXKUjwNfnHVU4GCh2Uz8wE=; b=j6KnuGW/mEYLklYB5TE7NcOXO8xK7dneap3hVniej3gXwHzvGnJsprCmuupDiJen3Q fKuflUWwdui9D0HkTLYZ44b29S/eodws9XDbpTrv+uhIcyf5znelsTC653vAbVvUAtYv Wngs4CYC15aPO7BmWrC1do86kbir/aNqWM63NfUxr0Cs6sP2cXZggM/r2h2upNpCPk9i WK4RSia3NDuSukXkgn+nX1CNUNqvqFrDk6i++R50kOzBloz9Hi5tvz8BB/EG6js7/UNT Ij7gRV2YJYllrZcMpJ2FgKKNWF5FquqTxujUmCxcQsXN73z97bZFTO2pYRLIZc52DhQJ vHRQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=G9m6VlPU; 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 q20-20020a170902b11400b001993762e5eesi933699plr.316.2023.03.09.19.14.55; Thu, 09 Mar 2023 19:15:08 -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=G9m6VlPU; 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 S229999AbjCJDIu (ORCPT + 99 others); Thu, 9 Mar 2023 22:08:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58916 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229910AbjCJDIp (ORCPT ); Thu, 9 Mar 2023 22:08:45 -0500 Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2095.outbound.protection.outlook.com [40.107.117.95]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 46BF9E20C4 for ; Thu, 9 Mar 2023 19:08:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QSq38KtgcXt6Yfqscsn9SZRX5IuAtXxGGoK9rmsefdN3uwqgX2O3YVyT3GPww+cOszRY0wBQFoT5Igq2WPF1sXpD0EHMlVxKYjMFBQoNnH+3sbGijqvWWhfMIEKVpt5ZpHuYKsZJT0rGsle3oZt4ZADIpSJav/4KysWlikK7If/7fJ1Xmm8lopeDHX+8bkwDt7Z+eootpd5vswKY4aXPiD60RVIm0oKWyhigEIOtMWXE3LMWowBC6ULKwWz0iyUCr6zy2o9UkERJvy28aA0osVp2Gigqv7iw7CAkY1/9RwBcYqpWylkH71SThaMINP4Yy/HT3C1S0Y6/KldZTYTP6w== 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=17DcBGO+6YLG7OAiYgPiEvXKUjwNfnHVU4GCh2Uz8wE=; b=EsSIwGHSqTJfOYMViDY2w+LLnm3C7aWAvNZOGYBj6a0XT4K9OCdgR+24Sn0rfecqFkNL2ICcrjQYjJ4gJHxnUC6uYjRAWq7slsPhFPG6sVLVj1+8w+zZZqGTLFiJyGAqMoEe2UjnT3btDLjEjCRr+1Ihj3FdIV8Go3VHTK8MVEijDHzYAUnAItIIDe6Suxb8ukxrnUXA/ffypZ0ZkjKh4yA/4wgupOMyMV9zNBi/HYw3lMJ/qOpApWZmP3IfdTjl7eifreY2+YvgPBRxKavXn0OzTFsFu8Pwfr8E8ZaqAv/dgUSLVAM4PZ9HxTWFGpA1e+CkxgU57IB7vcc3TRT3vA== 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=17DcBGO+6YLG7OAiYgPiEvXKUjwNfnHVU4GCh2Uz8wE=; b=G9m6VlPU/pTIPTc3mxE/dJgvPkF8gwWMNhmMBbYYUoB3wbgB6BzcXSg3LXCoNwPZ1M+SErwQyqU7ijJ/zaVBQwSNljb2Ocw8DYNT++WT6YyEUyLAtNwUmY22HlYvqL7VKYbtqsje+ALwDWSFAyeDEQU8+iDYsW83kPMoS2ZQtgKVwjfFHAGhzplUilPdE/mXy6BHEUvHqPRlZmM0+vbQM3KUhpr7BTVA3TPzVW/zAoKrJxL85x93g5DjZqrUZw/Vnb7C+FcvBvL2fuxxOGcGuTdu1AxsD/HLkB+bxNqHPFeCrveHG2bCP/xLCfFHyTY/uOKdFIr6gRVFXJb2ucu8mg== 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 KL1PR0601MB4275.apcprd06.prod.outlook.com (2603:1096:820:73::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6178.19; Fri, 10 Mar 2023 03:08:38 +0000 Received: from SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::daf6:5ebb:a93f:1869]) by SEZPR06MB5269.apcprd06.prod.outlook.com ([fe80::daf6:5ebb:a93f:1869%9]) with mapi id 15.20.6178.019; Fri, 10 Mar 2023 03:08:38 +0000 From: Yangtao Li To: almaz.alexandrovich@paragon-software.com, jack@suse.com, dushistov@mail.ru, brauner@kernel.org, ntfs3@lists.linux.dev Cc: linux-kernel@vger.kernel.org, Yangtao Li Subject: [PATCH 3/3] ufs: use wrapper i_blocksize() in ufs_get_locked_page() Date: Fri, 10 Mar 2023 11:08:21 +0800 Message-Id: <20230310030821.66090-3-frank.li@vivo.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20230310030821.66090-1-frank.li@vivo.com> References: <20230310030821.66090-1-frank.li@vivo.com> X-ClientProxiedBy: SI2PR02CA0026.apcprd02.prod.outlook.com (2603:1096:4:195::19) To SEZPR06MB5269.apcprd06.prod.outlook.com (2603:1096:101:78::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR06MB5269:EE_|KL1PR0601MB4275:EE_ X-MS-Office365-Filtering-Correlation-Id: 1c3a4540-9866-4fd3-198b-08db2114be93 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: UhG5xTP4yssg+TGcvj/ga8TmcgZaEsvLQBLGpTzdh2TySWBAi6hHFCWMFL3HwxkTzemFeDWajdPaCJhYGszBuXlptSKA2qDr3/nG5r0U3JfvPGkZdruVWSJWkCqOAHWX8MmuTIaVecJ6l0jJjntapL2+E7EKS4P6DbsPZ3jysEm68neOZ7nyM0QV+FeJrvkq/ILEP4yLRGv3YR5KViz2K6yMk6lh2lGBr+PKqMN2arMM7FWNqNS9m1h12AQnVjUZaVJ8Cr1OuIgFpfD/83WdBi4ErUBKVgd1aYyDKloeB1tY12ueeOm5RLjG3sa4AwD9EDr17g/IVCu4mn3KYsRVNulRY9IgFnQUNbByvanfe1WkkDF7h5mup1XeadPLgPIhrRFo3XLAsyTkGTOFWW5H8Y4w6/m+kg9YI8rQvf9zCJRP8gucEarMDZuMDI84Z8yxjTIoyOoyRScDnMZEcMhplP5UcQkQ+DMNmme5Gu7KbRb5W7w2rk3vCucV+LiDT7Nvm3hwch6VVUSRTUFrS6P5wdbiTI86Fdi/eZ6TmaYCNGppBospM5eAxtOHeBnPuYsnFqrdKKZD0MFfR5KIWQkGjnzfCNeK/dUhYHCaYMnmFICBpjLmxT/phIbDmi9rzwp1+dvMwCBtz+TFXqsj31smcZ8AzV7Aipq8FOh9pHYk5hRE/61TnKlg1m0HO8bVAtHGBGPGVI+14dQXaAsIJDGJtw== 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:(13230025)(4636009)(376002)(136003)(346002)(39860400002)(366004)(396003)(451199018)(4744005)(36756003)(5660300002)(83380400001)(107886003)(6666004)(26005)(6486002)(1076003)(2616005)(52116002)(6506007)(6512007)(478600001)(316002)(4326008)(66946007)(66476007)(8676002)(8936002)(41300700001)(66556008)(86362001)(186003)(38350700002)(38100700002)(2906002);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: OiZPcYuAz/Innc0cNx/lg+0dmtWeo8iiaQQPa3WJi5K3I2Xmu7AgmW0heOXud7NSu1leFnwkvEXg/jop5U5uEeI6c+eBqEgjaK7fQq2bvbZHidvTyD/BL5w7RBWyBnLp3ilKYt/1pYdCnsBxSSktJcGZlb6gaWXLy3i94MdqFKsH+7/3qpogTJ5AG07HGd6XRItaL5OQzKOfNQ1eBqFN+GLD3abatIDHViohQLjvVUXTMdxbDQnxJgIrCyvkd9BPeD3huBohYUUSt00VigJqsD5/CqN+Wx/175NnegUz9IAH7+7nrsqbTvpE5gkWLW+FoVsBoaOWnqoke5sAbN8X/lZcE05MwZxSBCmmHBqE6dbPVSLgIQEbn17VOair0pWeYIRxA78+QN8z5x2fs8HdQ8LkOGbhxgQJGxX9ChxFXumw/omA4RcPR+aE5dX1HMbAm9470Zb5IxkUXutBNi7eNWiDS5DnkbZ8e+m4l1l3DxaJNqrqObFFcL4DjgY5Yh8DmHvLoQY3vBlSC+5j/C+pOqDX+sMfWvUvWFhr+pGLy6/l9r4jWXuPK2NC98w0gLAUaqFtGfHduSy/Sl9ZuqvTGRCOs6BPhEY/5PsgSbKwMg1l2/51bo/emujJxV+tyjPoaR2MdfkFo3XlaSf0qnFLr4bySsU5rMmzcmrfE4ppCR21wcMN6qx/0PgG6AIXGLhs4N/c9gb8Zw+ev3KR6cBfRh1HG+0fr/22z+CVtBdck1CMTTKDSXTsgL63O1YH2S26GVtmyYxcKEk09DbwXFRuo510eYE/Kw3jX5aDQi0jECeWMpoQ6Mn6ROR6A1l4afLLC3U8kgGtu4V1tYEbpZQ506AQ2tPWfGotho+uQOuK/kKsb+lGf2St0scgNMIm86bv9tbvAhh0KgN+tyDGzVNzAicdTMFewj5P3fGMGXU5nZYnmBbMFS9u1BhpJkP7HPNFz7NRrFDDOGQtaYBfrbvbYQOfGIYgJuSNDcLCTarhXeZKu2vvxOoqtr4/UrLxOyKLTJyraoM2nlcviQjVvKE1IPkD5yRx17KkuqjeW/RqfpnzywHwGA2tuFwGnzDB75tHx6hvz1YVk/Hvte68vSkF/v6XnTYXra5LgFsL9MahAZzK/4zOHvrC+FVpSr80v+XTXEcgy86n40n4U9mkLBrsU6mAsgPwcPAjFsJYiK9Qnq9xJTv+UpsfjzRqIzeJQzEpdNXgcocK6wQr181IVl1v6evX9fc+l0IPBH+b9qUlHqOSHquU53GEVC9qBdc29YTXnlZgrZTzL26070SKFBBS3IDDbb3y96803gHoal1Xsy1t9V9SaBsgUtGdjN9G5FevFhiyuhsFen5015fsqz9+tafUVVzmLqOc2E/yYRbVkSwoRGk5o9qxFlebuqRjjTgevlIDqKx2UR4NZn2ztrUjWy4D67bVdCtuoyknpWYsAQMqAb0Gw0MDSbKo8/IO3sxoVctqs+8INDsIru/GjB0FVbSpHTOVqHTiLyDvIRRi1NgmRgJyMlc3NUzwAZmHYzgBfjzZ2FpMbC5b2YP3MLsb/8rW0SwvGN3VTXI6R6+nLT31BpDaafOehegq9HNn6EiL X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1c3a4540-9866-4fd3-198b-08db2114be93 X-MS-Exchange-CrossTenant-AuthSource: SEZPR06MB5269.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Mar 2023 03:08:38.5007 (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: o1dKmVNBxf3wLzjJvUXugW5BnccGdryKQ1ocjigesIpNmZhKVFyJeFFV1T7mvjZM6O8PJ1onXPiqTtRGIA7FCA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR0601MB4275 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,URIBL_BLOCKED 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?1759948946890674537?= X-GMAIL-MSGID: =?utf-8?q?1759948946890674537?= Convert to use i_blocksize() for readability. Signed-off-by: Yangtao Li --- fs/ufs/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ufs/util.c b/fs/ufs/util.c index 08ddf41eaaad..f9c1009ba98a 100644 --- a/fs/ufs/util.c +++ b/fs/ufs/util.c @@ -266,6 +266,6 @@ struct page *ufs_get_locked_page(struct address_space *mapping, } } if (!page_has_buffers(page)) - create_empty_buffers(page, 1 << inode->i_blkbits, 0); + create_empty_buffers(page, i_blocksize(inode), 0); return page; }