diff options
author | Mark Brown <broonie@kernel.org> | 2018-07-25 17:34:06 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2018-07-25 17:34:06 +0100 |
commit | ec665af5dd517c60ea1fbe791f6c8ecc443a61b6 (patch) | |
tree | adfe7a2578ecde6d65e927afe65b289efb458ab1 /drivers/misc/cxl/api.c | |
parent | 46543af4c9edc5701729b24dd395c23a40871aa9 (diff) | |
parent | f952480a8fc14ea24a4de9582e425924f98c92d3 (diff) |
Merge tag 'v4.14.58' into linux-linaro-lsk-v4.14lsk-v4.14-18.07
This is the 4.14.58 stable release
Diffstat (limited to 'drivers/misc/cxl/api.c')
-rw-r--r-- | drivers/misc/cxl/api.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/misc/cxl/api.c b/drivers/misc/cxl/api.c index a0c44d16bf30..c75daba57fd7 100644 --- a/drivers/misc/cxl/api.c +++ b/drivers/misc/cxl/api.c @@ -102,15 +102,15 @@ static struct file *cxl_getfile(const char *name, d_instantiate(path.dentry, inode); file = alloc_file(&path, OPEN_FMODE(flags), fops); - if (IS_ERR(file)) - goto err_dput; + if (IS_ERR(file)) { + path_put(&path); + goto err_fs; + } file->f_flags = flags & (O_ACCMODE | O_NONBLOCK); file->private_data = priv; return file; -err_dput: - path_put(&path); err_inode: iput(inode); err_fs: |