All of lore.kernel.org
 help / color / mirror / Atom feed
From: Al Viro <viro@zeniv.linux.org.uk>
To: Mateusz Guzik <mjguzik@gmail.com>
Cc: brauner@kernel.org, jack@suse.cz, linux-kernel@vger.kernel.org,
	linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH 1/2] fs: move getname and putname handlers into namei.h
Date: Mon, 1 Dec 2025 07:54:40 +0000	[thread overview]
Message-ID: <20251201075440.GZ3538@ZenIV> (raw)
In-Reply-To: <CAGudoHHnzB5-OWujgJsbyvCfo71QDkbgwsvWeqOady6BCi8Fcw@mail.gmail.com>

On Mon, Dec 01, 2025 at 07:27:05AM +0100, Mateusz Guzik wrote:
> self-NAK, i'm going to rebase on top of
> https://lore.kernel.org/linux-fsdevel/20251129170142.150639-1-viro@zeniv.linux.org.uk/
> when the time comes

	FWIW, I'm putting together struct filename-related
branches for the next cycle (trying to figure out what's the
best way to linearize the mess I've got).

	If you throw a patch on top of the series I've posted
on Friday (and it should shrink a whole lot - the damn thing
is static in fs/namei.c now, with cache initialization done
in the same place) I would be glad to apply it.

	Other series around struct filename for the next
cycle:

* DEFINE_CLASS(filename, struct filename *, putname(_T), getname(p), const char __user *p)
EXTEND_CLASS(filename, _kernel, getname_kernel(p), const char *p)
EXTEND_CLASS(filename, _flags, getname_flags(p, f), const char *p, unsigned int f)
EXTEND_CLASS(filename, _uflags, getname_uflags(p, f), const char *p, unsigned int f)
EXTEND_CLASS(filename, _maybe_null, getname_maybe_null(p, f), const char *p, unsigned int f)
EXTEND_CLASS(filename, _consume, no_free_ptr(p), struct filename *p)
and an bunch of conversions making use of that.  Generally I dislike RAII
patterns, but uses of struct filename make a reasonably good fit.

* change of calling conventions for do_filp_open() - let it DTRT when
it's given ERR_PTR() for name.  Surprising amount of error handling
in the callers (and callers of callers, etc.) folds into that.
One thing that is very tempting is s/do_filp_open/do_file_open/,
while we are at it...

* killing pointless checks for IS_ERR() before calling filename_lookup()
and vfs_path_parent_lookup() - those already treat ERR_PTR() for name
as "bail out immediately".

* [currently very tentative] dealing with __audit_inode().  It's
a surprisingly convoluted series, and it's not quite finished yet.
Not sure if that one won't end up slipping past 6.20...

Linearizing that stuff into something that would not be a hell wrt
merges is... interesting.

      reply	other threads:[~2025-12-01  7:54 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-29 15:54 [PATCH 1/2] fs: move getname and putname handlers into namei.h Mateusz Guzik
2025-11-29 15:55 ` [PATCH 2/2] fs: hide namei_cachep behind runtime const machinery Mateusz Guzik
2025-12-01  6:27 ` [PATCH 1/2] fs: move getname and putname handlers into namei.h Mateusz Guzik
2025-12-01  7:54   ` Al Viro [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20251201075440.GZ3538@ZenIV \
    --to=viro@zeniv.linux.org.uk \
    --cc=brauner@kernel.org \
    --cc=jack@suse.cz \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mjguzik@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.