this was already included by Christian, although with both predicts. I don't know if the other one fell off by accident.
regardless, this patch needs to get dropped On Sat, Nov 29, 2025 at 6:01 PM Al Viro <[email protected]> wrote: > > From: Mateusz Guzik <[email protected]> > > 1. we already expect the refcount is 1. > 2. path creation predicts name == iname > > I verified this straightens out the asm, no functional changes. > > Signed-off-by: Mateusz Guzik <[email protected]> > Link: https://patch.msgid.link/[email protected] > Reviewed-by: Jan Kara <[email protected]> > Signed-off-by: Christian Brauner <[email protected]> > --- > fs/namei.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/fs/namei.c b/fs/namei.c > index 37b13339f046..8530d75fb270 100644 > --- a/fs/namei.c > +++ b/fs/namei.c > @@ -285,7 +285,7 @@ void putname(struct filename *name) > return; > > refcnt = atomic_read(&name->refcnt); > - if (refcnt != 1) { > + if (unlikely(refcnt != 1)) { > if (WARN_ON_ONCE(!refcnt)) > return; > > -- > 2.47.3 >
