Message ID | 20240209142901.126894-6-da.gomez@samsung.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 68A03C48297 for <linux-mm@archiver.kernel.org>; Fri, 9 Feb 2024 14:29:21 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 8EB816B0085; Fri, 9 Feb 2024 09:29:12 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 808D06B0093; Fri, 9 Feb 2024 09:29:12 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id EE0966B0087; Fri, 9 Feb 2024 09:29:11 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id A3D3D6B008A for <linux-mm@kvack.org>; Fri, 9 Feb 2024 09:29:11 -0500 (EST) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 718BE804E4 for <linux-mm@kvack.org>; Fri, 9 Feb 2024 14:29:11 +0000 (UTC) X-FDA: 81772497702.01.2711838 Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by imf27.hostedemail.com (Postfix) with ESMTP id 67A3140018 for <linux-mm@kvack.org>; Fri, 9 Feb 2024 14:29:08 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=pass header.d=samsung.com header.s=mail20170921 header.b=h1JyNx4K; spf=pass (imf27.hostedemail.com: domain of da.gomez@samsung.com designates 210.118.77.12 as permitted sender) smtp.mailfrom=da.gomez@samsung.com; dmarc=pass (policy=none) header.from=samsung.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1707488948; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=FCbzId5tUUljaKo+tPW5dyPNAxWuqwZJmK4aFsnXX4M=; b=1zOeAKpv4QxPapxpRgcs1CsiFBcUFbW3tZMNJbGT7ggub9qHv6txrOoF+fRlTblL1ZV5zc HiA1TMC2uq7KX0+pFSkQWS+4mzGiplCjqggNo2v8GK6KPycNgE2FCk9TwQqkdCq8+Md/24 djznT4Hr6p/M/OPIqZTivDAF8HT1hxc= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1707488948; a=rsa-sha256; cv=none; b=sTHUqe/6Jag+8qtMeXp7wPYZSxBIJ3BgO7A7QG+wf7RbnYCWYOa+FrmrHxfgngMfpi/3HO 3+PR3V6HiOQrAuA9HAzgzzf3spRxkGxHVbvM6QJo4bup8bFAWnJ8w/dV9B+OZzH4PYDOoy i0eyrIzJpDdAEtsaPk2tFlNXVvGzvnw= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=pass header.d=samsung.com header.s=mail20170921 header.b=h1JyNx4K; spf=pass (imf27.hostedemail.com: domain of da.gomez@samsung.com designates 210.118.77.12 as permitted sender) smtp.mailfrom=da.gomez@samsung.com; dmarc=pass (policy=none) header.from=samsung.com Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20240209142906euoutp02c25feb24e8db4cb4e77dc12000cf772c~yOCaABEMJ2144921449euoutp02T for <linux-mm@kvack.org>; Fri, 9 Feb 2024 14:29:06 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20240209142906euoutp02c25feb24e8db4cb4e77dc12000cf772c~yOCaABEMJ2144921449euoutp02T DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1707488946; bh=FCbzId5tUUljaKo+tPW5dyPNAxWuqwZJmK4aFsnXX4M=; h=From:To:CC:Subject:Date:In-Reply-To:References:From; b=h1JyNx4KMrteOAQd2xuXTYL0v8bGy8abrDejKZj6MfmF7XkTeUYjJO/0mlcML6jxY LVoThPtZVowwXE1i4ym/GrWCFWwXiJyUXv4z+NRkk11J5mp12q17wL1A1sDkfrNlA3 SQ5JHpmxkcLYKefpwei3RORrbhDJGjstMZeYyjgw= Received: from eusmges2new.samsung.com (unknown [203.254.199.244]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20240209142906eucas1p2e47a246a10373a76799a079725583da1~yOCZtNsY_2329623296eucas1p2e; Fri, 9 Feb 2024 14:29:06 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges2new.samsung.com (EUCPMTA) with SMTP id FC.F5.09814.2B636C56; Fri, 9 Feb 2024 14:29:06 +0000 (GMT) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p1.samsung.com (KnoxPortal) with ESMTPA id 20240209142905eucas1p14498619591475e416a8163dbc96c90e4~yOCZTs0l-0937309373eucas1p16; Fri, 9 Feb 2024 14:29:05 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20240209142905eusmtrp2a5418fa28a2ffb3a4fc54948ca8a399d~yOCZTFUmN2110121101eusmtrp2b; Fri, 9 Feb 2024 14:29:05 +0000 (GMT) X-AuditID: cbfec7f4-711ff70000002656-40-65c636b2e6b8 Received: from eusmtip2.samsung.com ( [203.254.199.222]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 59.6F.09146.1B636C56; Fri, 9 Feb 2024 14:29:05 +0000 (GMT) Received: from CAMSVWEXC01.scsc.local (unknown [106.1.227.71]) by eusmtip2.samsung.com (KnoxPortal) with ESMTPA id 20240209142905eusmtip2236828047c1df8be3fea7df7e76daca2~yOCZK_AE42332823328eusmtip2R; Fri, 9 Feb 2024 14:29:05 +0000 (GMT) Received: from CAMSVWEXC02.scsc.local (2002:6a01:e348::6a01:e348) by CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 9 Feb 2024 14:29:05 +0000 Received: from CAMSVWEXC02.scsc.local ([::1]) by CAMSVWEXC02.scsc.local ([fe80::3c08:6c51:fa0a:6384%13]) with mapi id 15.00.1497.012; Fri, 9 Feb 2024 14:29:05 +0000 From: Daniel Gomez <da.gomez@samsung.com> To: "viro@zeniv.linux.org.uk" <viro@zeniv.linux.org.uk>, "brauner@kernel.org" <brauner@kernel.org>, "jack@suse.cz" <jack@suse.cz>, "hughd@google.com" <hughd@google.com>, "akpm@linux-foundation.org" <akpm@linux-foundation.org> CC: "dagmcr@gmail.com" <dagmcr@gmail.com>, "linux-fsdevel@vger.kernel.org" <linux-fsdevel@vger.kernel.org>, "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>, "linux-mm@kvack.org" <linux-mm@kvack.org>, "willy@infradead.org" <willy@infradead.org>, "hch@infradead.org" <hch@infradead.org>, "mcgrof@kernel.org" <mcgrof@kernel.org>, Pankaj Raghav <p.raghav@samsung.com>, "gost.dev@samsung.com" <gost.dev@samsung.com>, "Daniel Gomez" <da.gomez@samsung.com> Subject: [RFC PATCH 5/9] shmem: clear_highpage() if block is not uptodate Thread-Topic: [RFC PATCH 5/9] shmem: clear_highpage() if block is not uptodate Thread-Index: AQHaW2RUm+AjPQwetUKmMMbff0NR9g== Date: Fri, 9 Feb 2024 14:29:03 +0000 Message-ID: <20240209142901.126894-6-da.gomez@samsung.com> In-Reply-To: <20240209142901.126894-1-da.gomez@samsung.com> Accept-Language: en-US, en-GB Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [106.110.32.67] Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrPKsWRmVeSWpSXmKPExsWy7djP87qbzI6lGnz7JWYxZ/0aNovXhz8x Wpzt+81mcXrCIiaLp5/6WCxmT29mstiz9ySLxeVdc9gs7q35z2pxY8JTRovzf4+zWvz+MYfN gcdj56y77B4LNpV6bF6h5bFpVSebx6ZPk9g9Tsz4zeJxZsERdo/Pm+Q8Nj15yxTAGcVlk5Ka k1mWWqRvl8CVsfnoYcaCrWwVn2evZ2tgXMDaxcjJISFgInGt5S9TFyMXh5DACkaJH59XM0M4 XxglXnyZwwLhfGaUuL1yLTNMy7fPr6FaljNKXPr8iQ0kAVY14TovROI0o8TNg9dZ4QafW9fI CFLFJqApse/kJnaQhIjAc0aJ1t0fwRxmgdvMEnPaZ4FVCQt4SizqegN2o4hAgMTTM3uYIWw9 iR3L/oHVsAioSMybspIFxOYVsJJY9fI3E4jNKWAtMe/RerCbGAVkJR6t/MUOYjMLiEvcejKf CeIJQYlFs/dAPSQm8W/XQzYIW0fi7PUnjBC2gcTWpftYIGxFiY5jN9kg5uhJ3Jg6BcrWlli2 8DUzxA2CEidnPgGHmIRAG5fEm2nboRa4SHw7vARqsbDEq+Nb2CFsGYn/O+czTWDUnoXkvllI dsxCsmMWkh0LGFlWMYqnlhbnpqcWG+WllusVJ+YWl+al6yXn525iBKa50/+Of9nBuPzVR71D jEwcjIcYJTiYlUR4Q5YcSRXiTUmsrEotyo8vKs1JLT7EKM3BoiTOq5oinyokkJ5YkpqdmlqQ WgSTZeLglGpg2t5TWf4iSZh9092XzwPKirbc858nMGv3Bq84hrhUHXueczUiH/8KhifxflTZ 8XHP1qz//Oa50Te7BHP+XqjWkXt0tc/yr5aV2fJgf88dhcp7PgWktv/Jf3p/2/Mmya8ti7O8 L34zDvtSpN/A4vTqcalFA8vCnA87Wpn7uKdl3JozKYO5zCXh95tLCyU5Hi9cyqAbUXx+y+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z wZ7cMFFqgQ63sErWhyMsi/bPWiHE5su7aZ93p6fto1IbgaoPh6rOSC4TuT7Bjr3v7hKToyqv fvzmnXvU5oZg9/alcesN96txxYeEq+//4W8X81v15vdLX39EdQoXXjZavcs64DGTYa7njvI/ frq9vB8OR98yWiBWKpc5m/froW83QzusZu3/JDUreqv51QSF7+Xi84Pljm2493lqyJKbbPPa lhf66uzaySRnd1Rrl8SFnRofzpZ/qHAJrYroF3igEDzJpNvzQJvnRPcJroVOj9b2cFf8320z J2ORsxp/mdMZbg8LP76fGUKJnwPLH11v+SWrxFKckWioxVxUnAgAorJ4Z94DAAA= X-CMS-MailID: 20240209142905eucas1p14498619591475e416a8163dbc96c90e4 X-Msg-Generator: CA X-RootMTR: 20240209142905eucas1p14498619591475e416a8163dbc96c90e4 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20240209142905eucas1p14498619591475e416a8163dbc96c90e4 References: <20240209142901.126894-1-da.gomez@samsung.com> <CGME20240209142905eucas1p14498619591475e416a8163dbc96c90e4@eucas1p1.samsung.com> X-Rspamd-Queue-Id: 67A3140018 X-Rspam-User: X-Rspamd-Server: rspam11 X-Stat-Signature: a5wsbe3ay17whwbh1ced1fgwup1gepeq X-HE-Tag: 1707488948-463219 X-HE-Meta: U2FsdGVkX1/JZSDGHmrZOEZKyKEj4jPa1l2s0G8bXAGRbmVa8yMR+7Diwhp4tUg+HBQzhX93opOVSWQ2f6TbAv3Rj3N3OoLecjCpx+/RHeEwcBFKkk5PX4Ue3HMxCDOxjLCuGiPhLSNMl3qh+la6bWz1STafYYeVWmt9+QtL8iRE7PEbGCa8CD021utfOsoE72dKoRU44b/0ZnI7tTsmUnPtotsJ+kxbW9oj41Nb+5tToZvM0ITf+Xyp1FMe6LHlyvlhgrjo8duMNMowqSjokfs7owIyK1yoTJE1p/7+MH5LgusmPR5aus99YBpSNDJvpi1isPJ1e+fNYutsFsjD2Icni6dk8jCYELch18DdGkgdDcgNqPLngp+jRVHNzj6pkOiHKcSLuyl2MvOmozgnLwC9lO5V3accUevY31wA1DzSRe7m6GN2840aKHElg4SoGMnA+Yitns7/zuZcNJ6oUqXE6sXJkQJj9Inmp50+UEdwvHjGSeqYMfrRPUPyvSk6YT97U/upm1XkIYacWa+e/Q1rMljiLJdaH3uDTUNb3Tbpxu3RFy/c+GkreKZvgKbk7+jXsAZ4Bj3EMODvbpzJanE9pkaU6xAAHm8GvSHc0irUcuY++GfEEGQbkW7D4e8sf/mElk/We296k1sYZgYA4hZpYINUvOowdy4Kr3dM2E0ZrZQ1JMEatxjs0M2G52R0i3sipWETrkHe4+eeMSdiR21LIPhtCDXdMH2eEHUnKJbLyB3w/jp1pLi2dBzmTMq/V3tU6vSkyMNdxtsNh9bS03YSIYB0P5OPYmPPEL2xW3Daa4syX7TrkBCR3mp7md6LpnpM/GFEOkxJX5RUCUot+4hnuZu3N1lhHdu6LMJt3JG6AGRnwtAMEuF2efjvb2Sv/2s9wsLmak6brVozdXM3Kn2PSf8X/eBcdGTL9fRibLZK/gYdqbJUJyoag5+OeRKyuV94qk2BtU7diXWHtgp UkVgxFn+ qvZ9d9QBp5ZiI0iMaFrfzW3J8Q1+e8vMesVykNHWmnZWn3imijmJ0MbS1NDejDpD7z+pBlRVtNSN8f6ZqRlyUhssN+1c8BMTzJi2fptYlRdjwZaIDGX3ZAwWpmFcsWJqn0521GpkcDPLjv+CepUeZkJ8iVfUgs23L9nkbKUV5IlvfaMCDdKmmXdwKk3Bt1Auwsfeh4vQi3wIsg80BLoim7H5JGw== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
[RFC,1/9] splice: don't check for uptodate if partially uptodate is impl
|
expand
|
diff --git a/mm/shmem.c b/mm/shmem.c index 614cda767298..b6f9a60b179b 100644 --- a/mm/shmem.c +++ b/mm/shmem.c @@ -2253,7 +2253,8 @@ static int shmem_get_folio_gfp(struct inode *inode, pgoff_t index, long i, n = folio_nr_pages(folio); for (i = 0; i < n; i++) - clear_highpage(folio_page(folio, i)); + if (!shmem_is_block_uptodate(folio, i)) + clear_highpage(folio_page(folio, i)); flush_dcache_folio(folio); shmem_set_range_uptodate(folio, 0, folio_size(folio)); }
clear_highpage() is called for all the subpages (blocks) in a large folio when the folio is not uptodate. Do clear the subpages only when they are not uptodate. Signed-off-by: Daniel Gomez <da.gomez@samsung.com> --- mm/shmem.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)