All of lore.kernel.org
 help / color / mirror / Atom feed
* [git pull] pile 6: f_path stuff
@ 2025-10-03 22:15 Al Viro
  2025-10-03 22:31 ` Linus Torvalds
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Al Viro @ 2025-10-03 22:15 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-fsdevel, Christian Brauner

	The last of the stuff in -next - file->f_path constification.
Only one thing was modifying ->f_path of an opened file - acct(2).
Massaging that away and constifying a bunch of struct path * arguments
in functions that might be given &file->f_path ends up with the
situation where we can turn ->f_path into an anon union of const
struct path f_path and struct path __f_path, the latter modified only
in a few places in fs/{file_table,open,namei}.c, all for struct file
instances that are yet to be opened.

Several conflicts:
[fs/namei.c, include/linux/namei.h]: s/done_path_create/end_creating_path/
	in mainline.
[include/linux/namei.h]: end_removing_path() is a wrapper around the same thing,
	also needs struct path * argument constified.
[fs/open.c]: trivial conflict in finish_no_open()
[fs/nsfs.c]: less obvious: fs/nsfs.c:nsfs_export_open() needs struct path *
	argument constified.

See proposed resolution in #proposed.merge-2...

The following changes since commit a79765248649de77771c24f7be08ff4c96f16f7a:

  constify {__,}mnt_is_readonly() (2025-09-17 15:58:29 -0400)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git pull-f_path

for you to fetch changes up to 2f7d98f10b8f64525b2c74cae7d70ae5278eb654:

  Have cc(1) catch attempts to modify ->f_path (2025-09-27 20:18:41 -0400)

----------------------------------------------------------------
file->f_path constification

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

----------------------------------------------------------------
Al Viro (24):
      backing_file_user_path(): constify struct path *
      constify path argument of vfs_statx_path()
      filename_lookup(): constify root argument
      done_path_create(): constify path argument
      bpf...d_path(): constify path argument
      nfs: constify path argument of __vfs_getattr()
      rqst_exp_get_by_name(): constify path argument
      export_operations->open(): constify path argument
      check_export(): constify path argument
      ksmbd_vfs_path_lookup_locked(): root_share_path can be const struct path *
      ksmbd_vfs_kern_path_unlock(): constify path argument
      ksmbd_vfs_inherit_posix_acl(): constify path argument
      ksmbd_vfs_set_init_posix_acl(): constify path argument
      ovl_ensure_verity_loaded(): constify datapath argument
      ovl_validate_verity(): constify {meta,data}path arguments
      ovl_get_verity_digest(): constify path argument
      ovl_lower_dir(): constify path argument
      ovl_sync_file(): constify path argument
      ovl_is_real_file: constify realpath argument
      apparmor/af_unix: constify struct path * arguments
      configfs:get_target() - release path as soon as we grab configfs_item reference
      kernel/acct.c: saner struct file treatment
      Merge branches 'work.path' and 'work.mount' into work.f_path
      Have cc(1) catch attempts to modify ->f_path

 fs/bpf_fs_kfuncs.c                             |  2 +-
 fs/configfs/symlink.c                          | 33 ++++-----
 fs/file_table.c                                |  6 +-
 fs/internal.h                                  |  2 +-
 fs/namei.c                                     | 12 ++--
 fs/nfs/localio.c                               |  2 +-
 fs/nfsd/export.c                               |  4 +-
 fs/nfsd/export.h                               |  2 +-
 fs/open.c                                      | 10 +--
 fs/overlayfs/copy_up.c                         |  2 +-
 fs/overlayfs/file.c                            |  2 +-
 fs/overlayfs/overlayfs.h                       |  8 +--
 fs/overlayfs/super.c                           |  2 +-
 fs/overlayfs/util.c                            |  8 +--
 fs/pidfs.c                                     |  2 +-
 fs/smb/server/vfs.c                            |  8 +--
 fs/smb/server/vfs.h                            |  6 +-
 fs/stat.c                                      |  2 +-
 include/linux/exportfs.h                       |  2 +-
 include/linux/fs.h                             |  9 ++-
 include/linux/namei.h                          |  2 +-
 kernel/acct.c                                  | 96 ++++++++++----------------
 kernel/trace/bpf_trace.c                       |  2 +-
 security/apparmor/af_unix.c                    | 14 ++--
 tools/testing/selftests/bpf/bpf_experimental.h |  2 +-
 25 files changed, 107 insertions(+), 133 deletions(-)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [git pull] pile 6: f_path stuff
  2025-10-03 22:15 [git pull] pile 6: f_path stuff Al Viro
@ 2025-10-03 22:31 ` Linus Torvalds
  2025-10-03 22:42   ` Al Viro
  2025-10-04  0:44 ` pr-tracker-bot
  2025-10-04 16:15 ` Alexei Starovoitov
  2 siblings, 1 reply; 5+ messages in thread
From: Linus Torvalds @ 2025-10-03 22:31 UTC (permalink / raw)
  To: Al Viro; +Cc: linux-fsdevel, Christian Brauner

On Fri, 3 Oct 2025 at 15:16, Al Viro <viro@zeniv.linux.org.uk> wrote:
>
>   git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git pull-f_path

I see the branch 'work.f_path', but no such tag. Forgot to push out?

           Linus

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [git pull] pile 6: f_path stuff
  2025-10-03 22:31 ` Linus Torvalds
@ 2025-10-03 22:42   ` Al Viro
  0 siblings, 0 replies; 5+ messages in thread
From: Al Viro @ 2025-10-03 22:42 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-fsdevel, Christian Brauner

On Fri, Oct 03, 2025 at 03:31:23PM -0700, Linus Torvalds wrote:
> On Fri, 3 Oct 2025 at 15:16, Al Viro <viro@zeniv.linux.org.uk> wrote:
> >
> >   git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git pull-f_path
> 
> I see the branch 'work.f_path', but no such tag. Forgot to push out?

D'oh...  Sorry, pushed now.  I wonder why this
git request-pull origin vfs pull-f_path >/tmp/y
(straight from history) has not generated the usual warnings...

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [git pull] pile 6: f_path stuff
  2025-10-03 22:15 [git pull] pile 6: f_path stuff Al Viro
  2025-10-03 22:31 ` Linus Torvalds
@ 2025-10-04  0:44 ` pr-tracker-bot
  2025-10-04 16:15 ` Alexei Starovoitov
  2 siblings, 0 replies; 5+ messages in thread
From: pr-tracker-bot @ 2025-10-04  0:44 UTC (permalink / raw)
  To: Al Viro; +Cc: Linus Torvalds, linux-fsdevel, Christian Brauner

The pull request you sent on Fri, 3 Oct 2025 23:15:58 +0100:

> git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git pull-f_path

has been merged into torvalds/linux.git:
https://git.kernel.org/torvalds/c/50647a1176b7abd1b4ae55b491eb2fbbeef89db9

Thank you!

-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/prtracker.html

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [git pull] pile 6: f_path stuff
  2025-10-03 22:15 [git pull] pile 6: f_path stuff Al Viro
  2025-10-03 22:31 ` Linus Torvalds
  2025-10-04  0:44 ` pr-tracker-bot
@ 2025-10-04 16:15 ` Alexei Starovoitov
  2 siblings, 0 replies; 5+ messages in thread
From: Alexei Starovoitov @ 2025-10-04 16:15 UTC (permalink / raw)
  To: Al Viro; +Cc: Linus Torvalds, linux-fsdevel, Christian Brauner, rongtao, bpf

On Fri, Oct 03, 2025 at 11:15:58PM +0100, Al Viro wrote:
> ----------------------------------------------------------------
> file->f_path constification
> 
> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
> 
> ----------------------------------------------------------------
> Al Viro (24):
>       backing_file_user_path(): constify struct path *
>       constify path argument of vfs_statx_path()
>       filename_lookup(): constify root argument
>       done_path_create(): constify path argument
>       bpf...d_path(): constify path argument

This commit broke bpf, since you didn't update include/uapi/linux/bpf.h
and other places.

bpf mailing list was never cc-ed :(

Pushed the fix to bpf tree:
https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/commit/?id=de7342228b7343774d6a9981c2ddbfb5e201044b


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-10-04 16:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-03 22:15 [git pull] pile 6: f_path stuff Al Viro
2025-10-03 22:31 ` Linus Torvalds
2025-10-03 22:42   ` Al Viro
2025-10-04  0:44 ` pr-tracker-bot
2025-10-04 16:15 ` Alexei Starovoitov

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.