get rid of __dget()
authorAl Viro <viro@zeniv.linux.org.uk>
Sun, 29 Oct 2023 17:41:06 +0000 (13:41 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Sat, 18 Nov 2023 21:19:44 +0000 (16:19 -0500)
fold into the sole remaining caller

Reviewed-by: Christian Brauner <brauner@kernel.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/dcache.c

index c82ae731df9af780e58db42b45ba198375be2819..b8f1b54a1492260217544dee2e52426a72a46641 100644 (file)
@@ -948,11 +948,6 @@ static inline void __dget_dlock(struct dentry *dentry)
        dentry->d_lockref.count++;
 }
 
-static inline void __dget(struct dentry *dentry)
-{
-       lockref_get(&dentry->d_lockref);
-}
-
 struct dentry *dget_parent(struct dentry *dentry)
 {
        int gotref;
@@ -1002,7 +997,7 @@ static struct dentry * __d_find_any_alias(struct inode *inode)
        if (hlist_empty(&inode->i_dentry))
                return NULL;
        alias = hlist_entry(inode->i_dentry.first, struct dentry, d_u.d_alias);
-       __dget(alias);
+       lockref_get(&alias->d_lockref);
        return alias;
 }