summaryrefslogtreecommitdiffstats
path: root/fs/nfs/write.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-06-08 19:49:28 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-06-08 19:49:28 +0200
commit00fda1682efdbd62a20a8a21aee52d994c323c7f (patch)
treef49cee6c892019f193bf29985604951dd81ea94d /fs/nfs/write.c
parenttty: move linux/gsmmux.h to uapi (diff)
parentLinux 4.1-rc7 (diff)
downloadlinux-00fda1682efdbd62a20a8a21aee52d994c323c7f.tar.xz
linux-00fda1682efdbd62a20a8a21aee52d994c323c7f.zip
Merge 4.1-rc7 into tty-next
This fixes up a merge issue with the amba-pl011.c driver, and we want the fixes in this branch as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/nfs/write.c')
-rw-r--r--fs/nfs/write.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index d12a4be613a5..dfc19f1575a1 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -1845,12 +1845,15 @@ int nfs_wb_all(struct inode *inode)
trace_nfs_writeback_inode_enter(inode);
ret = filemap_write_and_wait(inode->i_mapping);
- if (!ret) {
- ret = nfs_commit_inode(inode, FLUSH_SYNC);
- if (!ret)
- pnfs_sync_inode(inode, true);
- }
+ if (ret)
+ goto out;
+ ret = nfs_commit_inode(inode, FLUSH_SYNC);
+ if (ret < 0)
+ goto out;
+ pnfs_sync_inode(inode, true);
+ ret = 0;
+out:
trace_nfs_writeback_inode_exit(inode, ret);
return ret;
}