From: Christoph Hellwig <hch@infradead.org>
To: Amir Goldstein <amir73il@gmail.com>
Cc: Christoph Hellwig <hch@infradead.org>,
Miklos Szeredi <miklos@szeredi.hu>,
Christian Brauner <brauner@kernel.org>,
Al Viro <viro@zeniv.linux.org.uk>, Jan Kara <jack@suse.cz>,
linux-fsdevel@vger.kernel.org, linux-unionfs@vger.kernel.org
Subject: Re: [PATCH v2 2/3] fs: introduce f_real_path() helper
Date: Sun, 11 Jun 2023 23:36:07 -0700 [thread overview]
Message-ID: <ZIa81+M0HeOzVQQb@infradead.org> (raw)
In-Reply-To: <CAOQ4uxjm4nXc4cHFCnk69RC2yshBmFBxMTuVxH3QQRm_6LRcSw@mail.gmail.com>
On Mon, Jun 12, 2023 at 09:28:40AM +0300, Amir Goldstein wrote:
> On Mon, Jun 12, 2023 at 7:36 AM Christoph Hellwig <hch@infradead.org> wrote:
> >
> > On Sun, Jun 11, 2023 at 04:27:31PM +0300, Amir Goldstein wrote:
> > > Overlayfs knows the real path of underlying dentries. Add an optional
> > > struct vfsmount out argument to ->d_real(), so callers could compose the
> > > real path.
> > >
> > > Add a helper f_real_path() that uses this new interface to return the
> > > real path of f_inode, for overlayfs internal files whose f_path if a
> > > "fake" overlayfs path and f_inode is the underlying real inode.
> >
> > I really don't like this ->d_real nagic. Most callers of it
> > really can't ever be on overlayfs.
>
> Which callers are you referring to?
Most users of file_dentry are inside file systems and will never
see the overlayfs path.
> > So I'd suggest we do an audit
> > of the callers of file_dentry and drop all the pointless ones
> > first, and improve the documentation on when to use it.
>
> Well, v3 is trying to reduce ->d_real() magic and the step
> after introducing the alternative path container is to convert
> file_dentry() to use the stored real_path instead of ->d_real().
Yeah, that makes this comment kinda irrelevant.
next prev parent reply other threads:[~2023-06-12 7:58 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-11 13:27 [PATCH v2 0/3] Handle notifications on overlayfs fake path files Amir Goldstein
2023-06-11 13:27 ` [PATCH v2 1/3] fs: rename FMODE_NOACCOUNT to FMODE_INTERNAL Amir Goldstein
2023-06-12 4:27 ` Christoph Hellwig
2023-06-12 6:08 ` Amir Goldstein
2023-06-12 6:11 ` Christoph Hellwig
2023-06-12 6:15 ` Christoph Hellwig
2023-06-12 6:32 ` Amir Goldstein
2023-06-12 6:35 ` Christoph Hellwig
2023-06-11 13:27 ` [PATCH v2 2/3] fs: introduce f_real_path() helper Amir Goldstein
2023-06-12 4:36 ` Christoph Hellwig
2023-06-12 6:28 ` Amir Goldstein
2023-06-12 6:36 ` Christoph Hellwig [this message]
2023-06-12 8:13 ` Amir Goldstein
2023-06-11 13:27 ` [PATCH v2 3/3] ovl: enable fsnotify events on underlying real files Amir Goldstein
2023-06-11 14:23 ` [PATCH v2 0/3] Handle notifications on overlayfs fake path files Miklos Szeredi
2023-06-11 16:55 ` Amir Goldstein
2023-06-11 17:52 ` Amir Goldstein
2023-06-11 19:12 ` Miklos Szeredi
2023-06-11 19:25 ` Amir Goldstein
2023-06-11 19:37 ` Miklos Szeredi
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=ZIa81+M0HeOzVQQb@infradead.org \
--to=hch@infradead.org \
--cc=amir73il@gmail.com \
--cc=brauner@kernel.org \
--cc=jack@suse.cz \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-unionfs@vger.kernel.org \
--cc=miklos@szeredi.hu \
--cc=viro@zeniv.linux.org.uk \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).