Re: [PATCH v2 12/15] ovl: change ovl_create_real() to get a new lock when re-opening created file.
From: Christian Brauner
Date: Tue Feb 24 2026 - 04:21:02 EST
On Mon, Feb 23, 2026 at 05:23:00AM -0800, Chris Mason wrote:
> NeilBrown <neilb@xxxxxxxxxxx> wrote:
> > From: NeilBrown <neil@xxxxxxxxxx>
> >
> > When ovl_create_real() is used to create a file on the upper filesystem
> > it needs to return the resulting dentry - positive and hashed.
> > It is usually the case the that dentry passed to the create function
> > (e.g. vfs_create()) will be suitable but this is not guaranteed. The
> > filesystem may unhash that dentry forcing a repeat lookup next time the
> > name is wanted.
> >
>
> Hi everyone,
>
> Amir suggested I run these through, and this commit was flagged:
>
> commit 62d49d1e44667e4f93bec415faabec5526992ac0
> Author: NeilBrown <neil@xxxxxxxxxx>
>
> ovl: change ovl_create_real() to get a new lock when re-opening created file.
>
> This commit changes ovl_create_real() to drop the directory lock and
> reacquire a new lock for lookup when the created dentry is unhashed. It
> also removes ovl_lookup_upper() which is no longer used.
>
> Signed-off-by: NeilBrown <neil@xxxxxxxxxx>
Fwiw, all patches that are applied go through AI review. My plan is to
have a discussion on getting automation set up for this at LSFMM so that
we can have the bot directly reply to reviews but under our control so
we can vet reviews.