aboutsummaryrefslogtreecommitdiffstats
path: root/fs/fuse/file.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/fuse/file.c')
-rw-r--r--fs/fuse/file.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/fuse/file.c b/fs/fuse/file.c
index d0ed60bc3188..adf7995232b8 100644
--- a/fs/fuse/file.c
+++ b/fs/fuse/file.c
@@ -610,7 +610,9 @@ static ssize_t fuse_direct_write(struct file *file, const char __user *buf,
610 ssize_t res; 610 ssize_t res;
611 /* Don't allow parallel writes to the same file */ 611 /* Don't allow parallel writes to the same file */
612 mutex_lock(&inode->i_mutex); 612 mutex_lock(&inode->i_mutex);
613 res = fuse_direct_io(file, buf, count, ppos, 1); 613 res = generic_write_checks(file, ppos, &count, 0);
614 if (!res)
615 res = fuse_direct_io(file, buf, count, ppos, 1);
614 mutex_unlock(&inode->i_mutex); 616 mutex_unlock(&inode->i_mutex);
615 return res; 617 return res;
616} 618}