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]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 513BBCCF9F8 for ; Fri, 7 Nov 2025 22:30:22 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 77E898E0009; Fri, 7 Nov 2025 17:30:21 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 755E08E0006; Fri, 7 Nov 2025 17:30:21 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 645158E0009; Fri, 7 Nov 2025 17:30:21 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 52F6B8E0006 for ; Fri, 7 Nov 2025 17:30:21 -0500 (EST) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id D3195160611 for ; Fri, 7 Nov 2025 22:30:20 +0000 (UTC) X-FDA: 84085255800.05.2EFFD81 Received: from flow-b3-smtp.messagingengine.com (flow-b3-smtp.messagingengine.com [202.12.124.138]) by imf21.hostedemail.com (Postfix) with ESMTP id DDE311C000A for ; Fri, 7 Nov 2025 22:30:18 +0000 (UTC) Authentication-Results: imf21.hostedemail.com; dkim=pass header.d=ownmail.net header.s=fm3 header.b=RSl+2Ovm; dkim=pass header.d=messagingengine.com header.s=fm3 header.b="U uwaUA5"; dmarc=pass (policy=none) header.from=ownmail.net; spf=pass (imf21.hostedemail.com: domain of neilb@ownmail.net designates 202.12.124.138 as permitted sender) smtp.mailfrom=neilb@ownmail.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1762554619; h=from:from:sender:reply-to: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=ZwkPbF9nsnt/dQhVAIT39vJvv4cO/9hCxNuUVfACV+4=; b=6++4zD0e6vk7jDq0ocVYCiZ9hTH0wA8QR1OeKzVHhmGZJzNXz2aFLoBVsMS1hj/M6TTx78 RMpfST8FF5sbbpmWmq24eWDOAMhdzVOZD+YWmOTiA67ASYStsm1VXknpGGMzV2SEfWCFgH 6Qc88ccTzo4/W4rlhtz+IgoFyJ78zwc= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1762554619; a=rsa-sha256; cv=none; b=5bgketYYGCLUXYgOmvT1/dTIGzty66eYQBtY1KTjI6AlIH6IZZlcDsclRcKnWftzLJ68+8 wBcTQqIuSNuZBq+rYWKPFf6NgilMRyr2ukpQlulJEj52VKSrORprwFRiWfvb+ZKC5LLmNK mJ3if9BiHPJKQIbzbjY/CvZ8h+Qtg2Q= ARC-Authentication-Results: i=1; imf21.hostedemail.com; dkim=pass header.d=ownmail.net header.s=fm3 header.b=RSl+2Ovm; dkim=pass header.d=messagingengine.com header.s=fm3 header.b="U uwaUA5"; dmarc=pass (policy=none) header.from=ownmail.net; spf=pass (imf21.hostedemail.com: domain of neilb@ownmail.net designates 202.12.124.138 as permitted sender) smtp.mailfrom=neilb@ownmail.net Received: from phl-compute-01.internal (phl-compute-01.internal [10.202.2.41]) by mailflow.stl.internal (Postfix) with ESMTP id 793A513004D8; Fri, 7 Nov 2025 17:30:15 -0500 (EST) Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-01.internal (MEProxy); Fri, 07 Nov 2025 17:30:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ownmail.net; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:reply-to:subject:subject:to:to; s=fm3; t= 1762554615; x=1762561815; bh=ZwkPbF9nsnt/dQhVAIT39vJvv4cO/9hCxNu UVfACV+4=; b=RSl+2OvmuLLOe4+H9eKpqC9RuowrdRH1jGe8qwVoOfdZ4I27ekS h347QoJGR7MbFLykEaO1W0OFpHRCXityFGk6z/rxp66MZo+KGt12LqqTInEw2CYx 3UVsJ0CnGd7WLdxCGmc3/jPkOyINCLxKnxNZklsUc3J3YikUBo2z3iRjiXQtMcY8 yq2lYeSEAVc2EWLQj1vGWye7x7mEIpjRksMMLReKQwYai89hN6GT0qLs9w2fXT/S aMCWnv9MVDkZT/W5daTSkcLSwc8NcaRJOdNaOs10bJXlSp1ckOlZsLuPaoex29HZ f8A5rEk01MsQM2q7vJ8gaDY5oWS9+X43upg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1762554615; x= 1762561815; bh=ZwkPbF9nsnt/dQhVAIT39vJvv4cO/9hCxNuUVfACV+4=; b=U uwaUA5HM3Mo8/6XH0sr3iEvIm8qkyq18WHGz5dmT4o3VuNPYFK0sT5/XwMakgpxt Ddom64XoCKrACYy2h4ZcgV+Tb8PW+9ZOvOvsw3PhcaXohwqssibqLdWfGuvkRTof t0u6Tm24jIfdJQPXMml4ZsBV3LhgKvo8idsWtpOv2NMgA6+6q/kF7vulaDiw1Wu8 QXM1pWPcrGZS5Ickwb89bPU2A6H7dDCOZcL68OGNiBqQPLXtlFiE4VEh4FSXHbCH jVfBahE281hNyxR2h1puiT9DkuKNVkHHM+JFBCiTT4EucRcOcOrhAYY2UT2c/Eoo JZasuDe2hIsiAlgrLmPZw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdeggdduledtkeejucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurheptgfgggfhvfevufgjfhffkfhrsehtjeertddttdejnecuhfhrohhmpefpvghilheu rhhofihnuceonhgvihhlsgesohifnhhmrghilhdrnhgvtheqnecuggftrfgrthhtvghrnh epudetfefhudevhedvfeeufedvffekveekgfdtfefggfekheejgefhteeihffggfelnecu vehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepnhgvihhlsg esohifnhhmrghilhdrnhgvthdpnhgspghrtghpthhtohepleejpdhmohguvgepshhmthhp ohhuthdprhgtphhtthhopehvihhrohesiigvnhhivhdrlhhinhhugidrohhrghdruhhkpd hrtghpthhtohepfhhrrghnkhdrlhhisehvihhvohdrtghomhdprhgtphhtthhopehlihhn uhigqdigfhhssehvghgvrhdrkhgvrhhnvghlrdhorhhgpdhrtghpthhtoheplhhinhhugi dquhhnihhonhhfshesvhhgvghrrdhkvghrnhgvlhdrohhrghdprhgtphhtthhopehlihhn uhigqdhnihhlfhhssehvghgvrhdrkhgvrhhnvghlrdhorhhgpdhrtghpthhtoheplhhinh hugidqnhhfshesvhhgvghrrdhkvghrnhgvlhdrohhrghdprhgtphhtthhopehlihhnuhig qdhkvghrnhgvlhesvhhgvghrrdhkvghrnhgvlhdrohhrghdprhgtphhtthhopehlihhnuh igqdhhrghruggvnhhinhhgsehvghgvrhdrkhgvrhhnvghlrdhorhhgpdhrtghpthhtohep lhhinhhugidqfhhsuggvvhgvlhesvhhgvghrrdhkvghrnhgvlhdrohhrgh X-ME-Proxy: Feedback-ID: iab3e480c:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Fri, 7 Nov 2025 17:29:44 -0500 (EST) Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 From: NeilBrown To: "Jeff Layton" Cc: "Eric Van Hensbergen" , "Latchesar Ionkov" , "Dominique Martinet" , "Christian Schoenebeck" , "David Sterba" , "David Howells" , "Marc Dionne" , "Alexander Viro" , "Christian Brauner" , "Jan Kara" , "Tigran A. Aivazian" , "Chris Mason" , "Xiubo Li" , "Ilya Dryomov" , "Jan Harkes" , coda@cs.cmu.edu, "Tyler Hicks" , "Jeremy Kerr" , "Ard Biesheuvel" , "Namjae Jeon" , "Sungjong Seo" , "Yuezhang Mo" , "Theodore Ts'o" , "Andreas Dilger" , "Jaegeuk Kim" , "Chao Yu" , "OGAWA Hirofumi" , "Miklos Szeredi" , "Andreas Gruenbacher" , "Viacheslav Dubeyko" , "John Paul Adrian Glaubitz" , "Yangtao Li" , "Richard Weinberger" , "Anton Ivanov" , "Johannes Berg" , "Mikulas Patocka" , "Muchun Song" , "Oscar Salvador" , "David Hildenbrand" , "David Woodhouse" , "Dave Kleikamp" , "Trond Myklebust" , "Anna Schumaker" , "Ryusuke Konishi" , "Konstantin Komarov" , "Mark Fasheh" , "Joel Becker" , "Joseph Qi" , "Bob Copeland" , "Mike Marshall" , "Martin Brandenburg" , "Amir Goldstein" , "Steve French" , "Paulo Alcantara" , "Ronnie Sahlberg" , "Shyam Prasad N" , "Tom Talpey" , "Bharath SM" , "Zhihao Cheng" , "Hans de Goede" , "Carlos Maiolino" , "Hugh Dickins" , "Baolin Wang" , "Andrew Morton" , "Kees Cook" , "Gustavo A. R. Silva" , "Jonathan Corbet" , "Matthew Wilcox (Oracle)" , linux-kernel@vger.kernel.org, v9fs@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-afs@lists.infradead.org, linux-btrfs@vger.kernel.org, ceph-devel@vger.kernel.org, codalist@coda.cs.cmu.edu, ecryptfs@vger.kernel.org, linux-efi@vger.kernel.org, linux-ext4@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, gfs2@lists.linux.dev, linux-um@lists.infradead.org, linux-mm@kvack.org, linux-mtd@lists.infradead.org, jfs-discussion@lists.sourceforge.net, linux-nfs@vger.kernel.org, linux-nilfs@vger.kernel.org, ntfs3@lists.linux.dev, ocfs2-devel@lists.linux.dev, linux-karma-devel@lists.sourceforge.net, devel@lists.orangefs.org, linux-unionfs@vger.kernel.org, linux-cifs@vger.kernel.org, samba-technical@lists.samba.org, linux-xfs@vger.kernel.org, linux-hardening@vger.kernel.org, linux-doc@vger.kernel.org, "Jeff Layton" Subject: Re: [PATCH v2] vfs: remove the excl argument from the ->create() inode_operation In-reply-to: <20251107-create-excl-v2-1-f678165d7f3f@kernel.org> References: <20251107-create-excl-v2-1-f678165d7f3f@kernel.org> Date: Sat, 08 Nov 2025 09:29:43 +1100 Message-id: <176255458305.634289.5577159882824096330@noble.neil.brown.name> Reply-To: NeilBrown X-Stat-Signature: cowoqx63953yrss1ozx4pk4m3ujj9azr X-Rspam-User: X-Rspamd-Queue-Id: DDE311C000A X-Rspamd-Server: rspam10 X-HE-Tag: 1762554618-314491 X-HE-Meta: U2FsdGVkX1/y7Su9SX0XwQAVhTJbkKK007D6M6rjX3CpAzVY04YBfnS8TT+Nb/GWh3uSM4aUBy2aeJLr9CmiZLbi6HseMZTuScfkonhAa4LcA8GykfCOoc/hnRAgt68ouL5eSanCvvyfYvHxvH2TP7BLLgP2nKJKeJr5+/nJNxLFz7hRzAJRhgdF9cTBoKajt0KRNHmwDPXxAysuEGUiNOCh7u8owuF5Y7NpspAogLOKZuwoI/d/iUqvDsDdT25hx0cwxRo9AExv2LGDlCitDTbTHMWNZwReChiPeqDSDAI/i/Ib+IlRUEmvkDhfIdIEndKoMa7TtNMgReL//AdpIex0rMFNf6V+O6cJt2bnY9J8P1hR6lE1jPcn4UhrKecPzKxduu4ZcNOtEwmQeOmaaVIR63sBbnmbHkI5rxwu0tSBsAdB+L/7T05k3w53au2niu3qBY63Q9OlvHVwq68HEReKu1oVlRUrXILyB/mluH0Ijj6fwwNGL5kSCGAe9Ff4bHMNzDCWdoTD7By3BmYGFzIG6JAtQWtypUPlaOAWwEqvoWHl/cFGuRsTjaL9epTiNhxRhg05Gd4iZgMmwBIIeE3Q0OAdfU2yRWrNY7XWUr8lZND2l599XH9LGmpT+X2Frrf/EZXfzpZIk2w92rWLIjB6DAHDcQZRBgPBxKqeCAkKkpFBzxdVZ2NZ3BMko8oCOTo10WtH3Ad2iWC22bOGmWjnPXvz4P/I5oDYDks6QOVJcJiZud/Gut6z92P2lYP011Wzg4Kwb6m5HTIsqUne4cpGxQvtSzYObujGjmY/XwMZ22cUJ3fVLpy+RNAG9Kn3Jn6NAEJDauY+DcCqVoiUJjLEPt4jAWYZ/0pxCYIuCN1pIodo3QLkI6TKV64OvqZkPVb19bjSOSrI3GL6Ayol66S7qrw9i2ztxFlFOB8uAuA+x46zyOtRzsv9QayiUcOsE6o2/f2W7uMiTyUgDzo iMODJHQE mtNortCiE5e63FEO+qqYFf1ykX3P6vXDwIhTlWm7g9uMkaA8qoY6cRZeGZd09/aJJeIpLVF1qw0s0v23EQXjDCJLSLn6+ZrnPO3Zk3LvxCbG3K8UNRMKYfzEUpHyxGUTluPf2bDIoe6+DPeT+RrVe2i5mVT3PTvAVqi3UPQ0a5SNSQc3/JD1lzF8QyKxMR8TNxHUwwRRu3QC3pNoqcY7FGcvi5rDwMdZ8fqiR4DNvtgbRQoZaaUv7RVKm0wIu/KfNcnOK0TKrHSaqCGPHBjP35+tYZlL7N7UhTrkpfHf3BdIC64gFYKJZZR+5SzzhAtARPIcZ 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: On Sat, 08 Nov 2025, Jeff Layton wrote: > With two exceptions, ->create() methods provided by filesystems ignore > the "excl" flag. Those exception are NFS and GFS2 which both also > provide ->atomic_open. > > Since ce8644fcadc5 ("lookup_open(): expand the call of vfs_create()"), > the "excl" argument to the ->create() inode_operation is always set to > true in vfs_create(). The ->create() call in lookup_open() sets it > according to the O_EXCL open flag, but is never called if the filesystem > provides ->atomic_open(). > > The excl flag is therefore always either ignored or true. Remove it, > and change NFS and GFS2 to act as if it were always true. > > Signed-off-by: Jeff Layton > --- > Note that this is based on top of the dir delegation series [1]. LMK > if the Documentation/ updates are too wordy. Patch is very nice. I don't think the documentation is too wordy. I think it is good that the two changes to the different files say essentially the same thing but use different words. That helps. Reviewed-by: NeilBrown > > Full disclosure: I did use Claude code to generate the first > approximation of this patch, but I had to fix a number of things that it > missed. I probably could have given it better prompts. In any case, I'm > not sure how to properly attribute this (or if I even need to). My understanding is that if you fully understand (and can defend) the code change with all its motivations and implications as well as if you had written it yourself, then you don't need to attribute whatever fancy text editor or IDE (e.g. Claude) that you used to help produce the patch. Thanks, NeilBrown