diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-07-04 18:15:03 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-07-04 18:15:03 +0300 |
commit | 7813029a509c0c92a5b16d846defaa50a2d3d7f1 (patch) | |
tree | 1962ab81537b7155d185f4b0b06c0323ff4dc509 /fs/fuse/dir.c | |
parent | 3c9a6793bde1feb368cd6ef113c08a40a37f7517 (diff) | |
parent | a99cde438de0c4c0cecc1d1af1a55a75b10bfdef (diff) | |
download | linux-7813029a509c0c92a5b16d846defaa50a2d3d7f1.tar.xz |
Merge 4.7-rc6 into staging-next
We want the staging fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/fuse/dir.c')
-rw-r--r-- | fs/fuse/dir.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c index ccd4971cc6c1..264f07c7754e 100644 --- a/fs/fuse/dir.c +++ b/fs/fuse/dir.c @@ -341,8 +341,10 @@ static struct dentry *fuse_lookup(struct inode *dir, struct dentry *entry, struct dentry *newent; bool outarg_valid = true; + fuse_lock_inode(dir); err = fuse_lookup_name(dir->i_sb, get_node_id(dir), &entry->d_name, &outarg, &inode); + fuse_unlock_inode(dir); if (err == -ENOENT) { outarg_valid = false; err = 0; @@ -1341,7 +1343,9 @@ static int fuse_readdir(struct file *file, struct dir_context *ctx) fuse_read_fill(req, file, ctx->pos, PAGE_SIZE, FUSE_READDIR); } + fuse_lock_inode(inode); fuse_request_send(fc, req); + fuse_unlock_inode(inode); nbytes = req->out.args[0].size; err = req->out.h.error; fuse_put_request(fc, req); |