Thread (27 messages) 27 messages, 4 authors, 2025-11-05

Re: [PATCH v4 09/17] vfs: add struct createdata for passing arguments to vfs_create()

From: NeilBrown <hidden>
Date: 2025-11-04 00:34:31
Also in: linux-cifs, linux-fsdevel, linux-nfs, linux-unionfs, linux-xfs, lkml, netfs

On Tue, 04 Nov 2025, NeilBrown wrote:
On Mon, 03 Nov 2025, Jeff Layton wrote:
quoted
vfs_create() has grown an uncomfortably long argument list, and a
following patch will add another. Convert it to take a new struct
createdata pointer and fix up the callers to pass one in.
I know Christian asked for this and he is a Maintainer so.....

but I would like say that I don't think this is a win.  The argument
list isn't *that* long, and all the args are quite different so there is
little room for confusion.

I would be in favour of dropping the "dir" arg because it is always
   d_inode(dentry->d_parent)
which is stable.

I would rather pass the vfsmnt rather than the idmap, then we could pass
"struct path", for both that and dentry, but I know Christian disagrees.

So if anyone really thinks the arg list is too long, I think there are
better solutions.  But I don't even think the length is a problem.
Also *every* caller of vfs_create() passes ".excl = true".  So maybe we
don't need that arg at all.

I think that the last time false might have been passed to vfs_create()
was before

Commit ce8644fcadc5 ("lookup_open(): expand the call of vfs_create()")

NeilBrown
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help