diff options
-rw-r--r-- | drivers/staging/pohmelfs/inode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/pohmelfs/inode.c b/drivers/staging/pohmelfs/inode.c index e9d41e439aa7..d004a9ddddbc 100644 --- a/drivers/staging/pohmelfs/inode.c +++ b/drivers/staging/pohmelfs/inode.c | |||
@@ -927,10 +927,10 @@ ssize_t pohmelfs_write(struct file *file, const char __user *buf, | |||
927 | mutex_unlock(&inode->i_mutex); | 927 | mutex_unlock(&inode->i_mutex); |
928 | WARN_ON(ret < 0); | 928 | WARN_ON(ret < 0); |
929 | 929 | ||
930 | if (ret > 0 && ((file->f_flags & O_SYNC) || IS_SYNC(inode))) { | 930 | if (ret > 0) { |
931 | ssize_t err; | 931 | ssize_t err; |
932 | 932 | ||
933 | err = sync_page_range(inode, mapping, pos, ret); | 933 | err = generic_write_sync(file, pos, ret); |
934 | if (err < 0) | 934 | if (err < 0) |
935 | ret = err; | 935 | ret = err; |
936 | WARN_ON(ret < 0); | 936 | WARN_ON(ret < 0); |