fs: dcache reduce branches in lookup path
[firefly-linux-kernel-4.4.55.git] / fs / btrfs / inode.c
index f9d2994a42a26dc198512277bc214753a9c563cc..63e4546b478acd144ad0c73fc886163be876f810 100644 (file)
@@ -4084,7 +4084,7 @@ struct inode *btrfs_lookup_dentry(struct inode *dir, struct dentry *dentry)
        int index;
        int ret;
 
-       dentry->d_op = &btrfs_dentry_operations;
+       d_set_d_op(dentry, &btrfs_dentry_operations);
 
        if (dentry->d_name.len > BTRFS_NAME_LEN)
                return ERR_PTR(-ENAMETOOLONG);