]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/blobdiff - fs/open.c
Merge tag 'linux-kselftest-4.8-rc1-update' of git://git.kernel.org/pub/scm/linux...
[mirror_ubuntu-zesty-kernel.git] / fs / open.c
index 93ae3cdee4ab093c8a23c0505a45d5673ccbc6b6..bf66cf1a9f5c4e186c14b7217414a51b5109c7b4 100644 (file)
--- a/fs/open.c
+++ b/fs/open.c
@@ -840,13 +840,13 @@ EXPORT_SYMBOL(file_path);
 int vfs_open(const struct path *path, struct file *file,
             const struct cred *cred)
 {
-       struct inode *inode = vfs_select_inode(path->dentry, file->f_flags);
+       struct dentry *dentry = d_real(path->dentry, NULL, file->f_flags);
 
-       if (IS_ERR(inode))
-               return PTR_ERR(inode);
+       if (IS_ERR(dentry))
+               return PTR_ERR(dentry);
 
        file->f_path = *path;
-       return do_dentry_open(file, inode, NULL, cred);
+       return do_dentry_open(file, d_backing_inode(dentry), NULL, cred);
 }
 
 struct file *dentry_open(const struct path *path, int flags,