From mboxrd@z Thu Jan 1 00:00:00 1970 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id CB151C02180 for ; Tue, 14 Jan 2025 00:53:16 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 343606B0085; Mon, 13 Jan 2025 19:53:16 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 2CBB46B0089; Mon, 13 Jan 2025 19:53:16 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0A8706B008A; Mon, 13 Jan 2025 19:53:16 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id D7AA16B0085 for ; Mon, 13 Jan 2025 19:53:15 -0500 (EST) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 88F56804AA for ; Tue, 14 Jan 2025 00:53:15 +0000 (UTC) X-FDA: 83004233550.20.167FB9E Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.18]) by imf18.hostedemail.com (Postfix) with ESMTP id 6A1831C0005 for ; Tue, 14 Jan 2025 00:53:11 +0000 (UTC) Authentication-Results: imf18.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=ggwGfpup; spf=pass (imf18.hostedemail.com: domain of dan.j.williams@intel.com designates 198.175.65.18 as permitted sender) smtp.mailfrom=dan.j.williams@intel.com; dmarc=pass (policy=none) header.from=intel.com; arc=reject ("signature check failed: fail, {[1] = sig:microsoft.com:reject}") ARC-Seal: i=2; s=arc-20220608; d=hostedemail.com; t=1736815992; a=rsa-sha256; cv=fail; b=FVtFeLRJNyeM/XhVT9eSKP+4k+168QyKvpyi+BDzn0k3+cJY2/Elsgm74Olya2y+0Y8tgD EiTjL9rpj1pvVmF/3bF50YSlX+BFg29LcFwcMGpra+pOPUU8YGSxlzPM9WbkhPPYh6Mr26 lMOnc+OXp41i4ouUTCuNSEE1uYYsf6w= ARC-Authentication-Results: i=2; imf18.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=ggwGfpup; spf=pass (imf18.hostedemail.com: domain of dan.j.williams@intel.com designates 198.175.65.18 as permitted sender) smtp.mailfrom=dan.j.williams@intel.com; dmarc=pass (policy=none) header.from=intel.com; arc=reject ("signature check failed: fail, {[1] = sig:microsoft.com:reject}") ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1736815992; 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: in-reply-to:in-reply-to:references:references:dkim-signature; bh=QSFxISSDfwluD9O4dg9MCl2MFC9m1ysTr2vDH0AoHOs=; b=Q63tiK717P6RzWknKQ376CaimFW2iO8cz9oPTV/zs0ZWUQTVKeRF8lCP4u+ywDtRB9INQG PbVn57N+FEHGKizVbyqt6JuiO2cKJ/t6pO5FyJo18l48pNMPVbmdViblegVMtupnfpjy+1 6/ux2Zlwe+aCwkI8Ks1PW9eBOBSV+F4= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1736815992; x=1768351992; h=date:from:to:cc:subject:message-id:references: in-reply-to:mime-version; bh=Fy+oWXZoO04vfjx8tNv5ufVOKcON14nWaCUXDKfmSp0=; b=ggwGfpup7YD7UK7SnxWGeTZb3lvLckNhZ13e6tp3QFiYJziSAvuhtR46 cOGRKB9jYerydmiom8wJhvmh3AqoqR+5KDxZvuLwueS+scRNkrxRN/x7M 5r6wou/KfltoG7PRjJctl+CAUiduC2tDp5WoeS2gtrUyvXYrn4LLs2vZc gsIGShT6rVgXR2S7GioAMHUVh/lx1JZmivKBZWxqXWFrwVzDmp1TBFrkU 4QEsZeBtZ2yAWSb1NiPeSuWSM2PppgAOqsoflG4aIv4EaUoXXTZKM3spa 0w0Ye0shTPiYM4ihHe3fYN8hkwYZeJp6jPmcqHDF3oY7T5y1LREyCGCqE Q==; X-CSE-ConnectionGUID: OzUanDcNSZ+mo1jifCX6Gg== X-CSE-MsgGUID: O/LOBAOQQT+sCzVIU9sDrw== X-IronPort-AV: E=McAfee;i="6700,10204,11314"; a="37214038" X-IronPort-AV: E=Sophos;i="6.12,310,1728975600"; d="scan'208";a="37214038" Received: from orviesa004.jf.intel.com ([10.64.159.144]) by orvoesa110.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Jan 2025 16:53:10 -0800 X-CSE-ConnectionGUID: Xdfvy6ZzRY2Dp4I70+/E0A== X-CSE-MsgGUID: Yd2HPV1ISBiIEUdNw3SCvQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,312,1728975600"; d="scan'208";a="109632548" Received: from orsmsx601.amr.corp.intel.com ([10.22.229.14]) by orviesa004.jf.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 13 Jan 2025 16:53:10 -0800 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.44; Mon, 13 Jan 2025 16:53:09 -0800 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.44 via Frontend Transport; Mon, 13 Jan 2025 16:53:09 -0800 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (104.47.57.169) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.44; Mon, 13 Jan 2025 16:53:09 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=a+s8H65ic82k/zpoElmrgYd+q1o5MPG1Y29NJHi53TFJVZ6SsLtDgDzQ5y6A+EZ9+8fx3ktYvAThbUROaiCBQ+q12if3sTcb8ZTKSFIu5dRYxKF4Nrbp/qvvktbfja2qm9gLMEWS6jY+jq40Rr3AXpkUOo2OlV6Y/89FWrhCl95gIATAXKdtdKMIKwNT9SrhH5v//o5t0LlTIuZbGjtw4s5HlGx+EJqo8FU+f4ZyLmTl/338965PCFkWRzB02yv75hOm85JXgiqKDfH6Dvb8s+tDlVO6yeSTeYSAa+fn8co1l5u5wJcQhS//kCJOpfmahMwoL83ezClKuLKUFUhtiA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=QSFxISSDfwluD9O4dg9MCl2MFC9m1ysTr2vDH0AoHOs=; b=MWq/TmrCSbtTCqA/oz2t+P7wZsbb9MqoKXK/q/jFpgxY5Ms/LoWdNkWSg5/ECQbeObaah3/QjyH6Qm5ihF6ZVNDODn16V8NHj+eQ83uDgKxrFzb6aVpDELOnikzhbOirdqGuwkfHYKSyR4yEwGgQFkJ5UEZiGx/EeXZYfb5/cTS1CYrsHuiAh78qPII84bHWhDxrmEOd8D8Uu9sJxyRjYgHhdLrY8Becz4o7jqKU7s7nSGY7LukYRBToSIFou5PJ81sgvF1kZhsFQMnNt5l5BCn4uHcO8sTYiU14jKiw5rT07Im/XpnR4wQtaoLZQAtoxbxim4AQ2qY3AI7LOlne/w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from PH8PR11MB8107.namprd11.prod.outlook.com (2603:10b6:510:256::6) by CH3PR11MB8774.namprd11.prod.outlook.com (2603:10b6:610:1cd::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8335.18; Tue, 14 Jan 2025 00:52:38 +0000 Received: from PH8PR11MB8107.namprd11.prod.outlook.com ([fe80::6b05:74cf:a304:ecd8]) by PH8PR11MB8107.namprd11.prod.outlook.com ([fe80::6b05:74cf:a304:ecd8%5]) with mapi id 15.20.8335.011; Tue, 14 Jan 2025 00:52:38 +0000 Date: Mon, 13 Jan 2025 16:52:34 -0800 From: Dan Williams To: Alistair Popple , , , CC: , Alistair Popple , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , Subject: Re: [PATCH v6 08/26] fs/dax: Remove PAGE_MAPPING_DAX_SHARED mapping flag Message-ID: <6785b5525dd93_20fa294f2@dwillia2-xfh.jf.intel.com.notmuch> References: Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: X-ClientProxiedBy: MW4PR03CA0149.namprd03.prod.outlook.com (2603:10b6:303:8c::34) To PH8PR11MB8107.namprd11.prod.outlook.com (2603:10b6:510:256::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PH8PR11MB8107:EE_|CH3PR11MB8774:EE_ X-MS-Office365-Filtering-Correlation-Id: db15e0ec-4b30-4357-c226-08dd3435be4f X-LD-Processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|1800799024|7416014|366016|7053199007; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?lm9PI4H+wuCESxA3g7ET6waP+GNpzkJxwe5KTDwsIeYBp7L5aJnuJyrhFkX2?= =?us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vgOEAeaYSEqDXh9?= =?us-ascii?Q?BKDld8/SFohqHga8ylL2VoMoD/arcfKwukXEuaQ1krUozmvQj7ac13bXpAcY?= =?us-ascii?Q?Rh7YfvsftxTSR19Ei8f4gIOeE38AZePywkSzQBh1B+wbf/E4fs0lKfmDLihR?= =?us-ascii?Q?i2Vbx+ckSf+z0jzWMcDjYRWmCMbVBRrjPPJAAFXZ12jHkX64xUMp2AiAF34D?= =?us-ascii?Q?VfB9u9ndWKxJ6/jU9NQ9mFc8EUH5WQ1x6lwV6+C+kUPkJqxrdnD4PQK0EXQq?= =?us-ascii?Q?LqbudIDloNIYRjFxHQyawyHKgpQ0OSHw0kZGc8hi13JiT69ckhJTSupDijLb?= =?us-ascii?Q?3RHMg/LtbYyQeDX+/sU7g59p7J5Obaqhak/skdg6gF0OoMvWcgV2s+qjErhs?= =?us-ascii?Q?3Rje3GRHNNINAkWCuEfvUB8iZb2SfdJObJv1MmAsDz2yN32AT83uwB+GuuJ5?= =?us-ascii?Q?NXAwhq8W0Fsfat/y2vEA+5qG7PWv?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH8PR11MB8107.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(376014)(1800799024)(7416014)(366016)(7053199007);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?t7kILchC1jUZPK8aasoyuhFxfE9oHnrN6JsvA4pP9BDeXZ5d6SGPO5pJ6+68?= =?us-ascii?Q?LaPLoM9wFyZegGpbuGvPfe2Iqq6jwYH68xmu7WcELiXyd1yJ3t1tLhJSP43T?= =?us-ascii?Q?svVgGG9n8wnsc7nMd7h98zvIk8D2gLZ84Xmog+a7hBPbGUQIok5O4vdjjRpz?= =?us-ascii?Q?bf2sbqWJ7vRBNxcORm+cRefiCTRLCJMOHKGsyo3chewfR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W7MLoRd0apuPVBA587vyCVOFGMOgIvN/sz+OWmw+WKwCy1vXXoRO?= =?us-ascii?Q?ADSovHrs3tmrJP708B6ko7DeSlTnzcXQZPztHBixlfNHwLEz3h7F+FwcNeE0?= =?us-ascii?Q?5sGz5RRQ1ElLF+dbBpQdawzf0xrC+XL5dxg+eLfopz/8VlCak0zv+tmrKcq3?= =?us-ascii?Q?Tr+1dKP54gW35FONI3E6Wko9IMqQEoM44CUBfnwL/pvBZHeCGgQAYCsFPfdY?= =?us-ascii?Q?fEOtbIJSLROTjT3V9qnmtOR9McQqW/PfyNW4ELsaeYiI5+UtVELaHsftHzMm?= =?us-ascii?Q?ilg7W14IOvX1CYU7bnaGv1XMEKhEtdTzg7pwMlh5707+N9uOi5BVJ92z3dF+?= =?us-ascii?Q?zsK/+7hHCN+p1pzPQD4NkFJfzzUOC7tyBAQx6OAd65gToBqGULjcPihRLAzg?= =?us-ascii?Q?X4vXg33SAMFu6NxYhmiAvxGFbEOHpzVMbqKHze9mAxLYIl/im6oCCVf5s4ww?= =?us-ascii?Q?IbXna+Y9j8ACOiyhG+WvDtgAh6ptYhNAtMoGTOIJoxr1mbN2a/BNzuIBdSH6?= =?us-ascii?Q?rw=3D=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: db15e0ec-4b30-4357-c226-08dd3435be4f X-MS-Exchange-CrossTenant-AuthSource: PH8PR11MB8107.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Jan 2025 00:52:38.8715 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: An4+64mw0PfVogtGYCWgxhrg/FuW2o7tBiugwuVa0To8jeh3MXKNhHC5yF0XbaNIbTi8viteIXLs2HHa7UYBEyBzFwKIzwdlk1jiLx/471g= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH3PR11MB8774 X-OriginatorOrg: intel.com X-Rspamd-Queue-Id: 6A1831C0005 X-Stat-Signature: 9uqr7oig934xqrfmbiqk9wmdwe6n1o76 X-Rspam-User: X-Rspamd-Server: rspam09 X-HE-Tag: 1736815991-400098 X-HE-Meta: U2FsdGVkX1+QYri/SVTNYEWB9c+wO170JzfPURAsGN6fowM5ywifb9VDqlDw+FkKXne0N2TkCWLfaab6zg+eJOSJ83IwJ/m+jlDU7HVUbU+GzSPz51qH1guHORF+GrhKcN5ZGuoFz9cLXtR7Z6TKmmXSEJKoZpKFz/3gqImOzEOUq3aC77tlVbgea5JQAME6pji4GOtT7RTNbOZXyGYPrOoUJ1s0lqh+aTmkXID/I73VJHKAwqiAmZQQTV4AkoqV9yPiKSTbA5x/ybHC3uk3nQSfrqD/l/+gb9TLxtqv3dtmGvVrCWGgcFxVs9JPqvjxDor65XnpZoLTjf0eJoTKrtz6X6o7vsJVHEKMGil6FXK89RVm7p+CCrwYt0kUzAY8LWgTT9XO6cPYC3psx9HtF+UKhPjBLZZrfE2eJs1JBOo+QdUUbTZILt9h9t/pFMQF4vtDtQ8y5WWM0CbyMglRbu5WtFKyx9m0yZUWc+XPtVXaCWj/GMTbaKBHtWmOePYn9yA2NS3caa7FGPcJ2/+fSYbTenESGCEgrdvWUofxTsjxYA8Xk30GuRX2CmNW9Q498X9Z7Zpl6RcSTvUMKeCQEZXkTYL247y2Peefy80TTA97Zbqp8/VgeCkxXvoB9oZceqttQa/ut2G9dEaRKpP1dKFmAj2aEGYbNy86faO30nBOzwdW0MpcS8WMWzJrLPJqDPiBoNghe8O0DncE1GnieqTFfZ3dCEvr1AU9EqHwwruw+4QMZuDTL42ZuxpCjdrzeAvyXuEconwJU+Sj0QhgDNxEvyIFCySdzFAJ2l43aQCDBmFgm+QLb6iK1eEP4cfggFbVZz1LsDAPEgAaIn64bi5u/T0bvzM0Nyhdc9hJyLj9cakLQIJMB09EhyEucMxa+npbc4eMSOzjosS6wnXrb/wrbXASecGoM2RaIu9L87Cv5EKYxUuWtSQuajh/vAsbFTssDCNCjiK/+jNv5m7 lXYG71M/ SvWtOiGpVPRac7cNA++U3aUitcQuNuZFT461YuyBv9kSqqebfNsUxHGgEN/rrGSnrkQsTgWXLgiGCN0ld7ED7c0HoBNKG5c+cAYsAfXMXfoew40sUugtvZrYXmTQkIYuzefFGG/nDAgkk5wTmkiQMYmuEjixNEIEemE4ww3PGnKVbFbdP8K4J8XXjaQpFZvF5Ooi+yqUnU8SVItVlmBgoRzCz33WO+H4upc2aFjmgz2pX8LPuQQ0ELMmhOGm/TiYjmqDVhqbNHzgN5/wx7GppISxYy3pL7zJ3g93ad6SfRVTftauoyTC4eWYGCboO+kpQo0vI4EZAfumyxwJhHzXcu1V9cFNSoBKeaP0wIqSsrbXhsGU+r2arudslsEiFjKls8ljO1hJuxW9H+ta/2PphaB0QvRZbkLrmS3eKCl7bRg9ZxhhvDb9NK+zSSjU7qn8YO+57UXEnUQyCYQExPpDFd5HzmPTsFAtmybhqS2mNWm1PUV9im6UhhHutCLuLPGH6474Ap0Q9IP/+zCgzvjvaw+nPCOfSl64OOqxO 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: List-Subscribe: List-Unsubscribe: Alistair Popple wrote: > PAGE_MAPPING_DAX_SHARED is the same as PAGE_MAPPING_ANON. I think a bit a bit more detail is warranted, how about? The page ->mapping pointer can have magic values like PAGE_MAPPING_DAX_SHARED and PAGE_MAPPING_ANON for page owner specific usage. In fact, PAGE_MAPPING_DAX_SHARED and PAGE_MAPPING_ANON alias the same value. > This isn't currently a problem because FS DAX pages are treated > specially. s/are treated specially/are never seen by the anonymous mapping code and vice versa/ > However a future change will make FS DAX pages more like > normal pages, so folio_test_anon() must not return true for a FS DAX > page. > > We could explicitly test for a FS DAX page in folio_test_anon(), > etc. however the PAGE_MAPPING_DAX_SHARED flag isn't actually > needed. Instead we can use the page->mapping field to implicitly track > the first mapping of a page. If page->mapping is non-NULL it implies > the page is associated with a single mapping at page->index. If the > page is associated with a second mapping clear page->mapping and set > page->share to 1. > > This is possible because a shared mapping implies the file-system > implements dax_holder_operations which makes the ->mapping and > ->index, which is a union with ->share, unused. > > The page is considered shared when page->mapping == NULL and > page->share > 0 or page->mapping != NULL, implying it is present in at > least one address space. This also makes it easier for a future change > to detect when a page is first mapped into an address space which > requires special handling. > > Signed-off-by: Alistair Popple > --- > fs/dax.c | 45 +++++++++++++++++++++++++-------------- > include/linux/page-flags.h | 6 +----- > 2 files changed, 29 insertions(+), 22 deletions(-) > > diff --git a/fs/dax.c b/fs/dax.c > index 4e49cc4..d35dbe1 100644 > --- a/fs/dax.c > +++ b/fs/dax.c > @@ -351,38 +351,41 @@ static unsigned long dax_end_pfn(void *entry) > for (pfn = dax_to_pfn(entry); \ > pfn < dax_end_pfn(entry); pfn++) > > +/* > + * A DAX page is considered shared if it has no mapping set and ->share (which > + * shares the ->index field) is non-zero. Note this may return false even if the > + * page is shared between multiple files but has not yet actually been mapped > + * into multiple address spaces. > + */ > static inline bool dax_page_is_shared(struct page *page) > { > - return page->mapping == PAGE_MAPPING_DAX_SHARED; > + return !page->mapping && page->share; > } > > /* > - * Set the page->mapping with PAGE_MAPPING_DAX_SHARED flag, increase the > - * refcount. > + * Increase the page share refcount, warning if the page is not marked as shared. > */ > static inline void dax_page_share_get(struct page *page) > { > - if (page->mapping != PAGE_MAPPING_DAX_SHARED) { > - /* > - * Reset the index if the page was already mapped > - * regularly before. > - */ > - if (page->mapping) > - page->share = 1; > - page->mapping = PAGE_MAPPING_DAX_SHARED; > - } > + WARN_ON_ONCE(!page->share); > + WARN_ON_ONCE(page->mapping); Given the only caller of this function is dax_associate_entry() it seems like overkill to check that a function only a few lines away manipulated ->mapping correctly. I don't see much reason for dax_page_share_get() to exist after your changes. Perhaps all that is needed is a dax_make_shared() helper that does the initial fiddling of '->mapping = NULL' and '->share = 1'? > page->share++; > } > > static inline unsigned long dax_page_share_put(struct page *page) > { > + WARN_ON_ONCE(!page->share); > return --page->share; > } > > /* > - * When it is called in dax_insert_entry(), the shared flag will indicate that > - * whether this entry is shared by multiple files. If so, set the page->mapping > - * PAGE_MAPPING_DAX_SHARED, and use page->share as refcount. > + * When it is called in dax_insert_entry(), the shared flag will indicate > + * whether this entry is shared by multiple files. If the page has not > + * previously been associated with any mappings the ->mapping and ->index > + * fields will be set. If it has already been associated with a mapping > + * the mapping will be cleared and the share count set. It's then up to the > + * file-system to track which mappings contain which pages, ie. by implementing > + * dax_holder_operations. This feels like a good comment for a new dax_make_shared() not dax_associate_entry(). I would also: s/up to the file-system to track which mappings contain which pages, ie. by implementing dax_holder_operations/up to reverse map users like memory_failure() to call back into the filesystem to recover ->mapping and ->index information/ > */ > static void dax_associate_entry(void *entry, struct address_space *mapping, > struct vm_area_struct *vma, unsigned long address, bool shared) > @@ -397,7 +400,17 @@ static void dax_associate_entry(void *entry, struct address_space *mapping, > for_each_mapped_pfn(entry, pfn) { > struct page *page = pfn_to_page(pfn); > > - if (shared) { > + if (shared && page->mapping && page->share) { How does this case happen? I don't think any page would ever enter with both ->mapping and ->share set, right? If the file was mapped then reflinked then ->share should be zero at the first mapping attempt. It might not be zero because it is aliased with index until it is converted to a shared page.