[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20231123215234.GQ38156@ZenIV>
Date: Thu, 23 Nov 2023 21:52:34 +0000
From: Al Viro <viro@...iv.linux.org.uk>
To: Gabriel Krisman Bertazi <gabriel@...sman.be>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
Christian Brauner <brauner@...nel.org>, tytso@....edu,
linux-f2fs-devel@...ts.sourceforge.net, ebiggers@...nel.org,
linux-fsdevel@...r.kernel.org, jaegeuk@...nel.org,
linux-ext4@...r.kernel.org
Subject: Re: [f2fs-dev] [PATCH v6 0/9] Support negative dentries on
case-insensitive ext4 and f2fs
On Thu, Nov 23, 2023 at 02:06:39PM -0500, Gabriel Krisman Bertazi wrote:
> >
> > 4. d_move() and d_exchange() would ignore the value returned by __d_move();
> > __d_unalias() turn
> > __d_move(alias, dentry, false);
> > ret = 0;
> > into
> > ret = __d_move(alias, dentry, Splice);
> > d_splice_alias() turn
> > __d_move(new, dentry, false);
> > write_sequnlock(&rename_lock);
> > into
> > err = __d_move(new, dentry, Splice);
> > write_sequnlock(&rename_lock);
> > if (unlikely(err)) {
> > dput(new);
> > new = ERR_PTR(err);
> > }
> > (actually, dput()-on-error part would be common to all 3 branches
> > in there, so it would probably get pulled out of that if-else if-else).
> >
> > I can cook a patch doing that (and convert the obvious beneficiaries already
> > in the tree to it) and throw it into dcache branch - just need to massage
> > the series in there for repost...
>
> if you can write that, I'll definitely appreciate it. It will surely
> take me much longer to figure it out myself.
Speaking of other stuff in the series - passing the expected name to
->d_revalidate() is definitely the right thing to do, for a lot of
other reasons. We do have ->d_name UAF issues in ->d_revalidate()
instances, and that allows to solve them nicely.
It's self-contained (your 2/9 and 3/9), so I'm going to grab that
into a never-rebased branch, just to be able to base the followups
propagating the use of stable name into instances.
Anyway, need to finish writing up the description of existing dcache
series first...
Powered by blists - more mailing lists