diff options
author | Jeff Layton <jlayton@redhat.com> | 2017-07-07 15:20:53 -0400 |
---|---|---|
committer | Jeff Layton <jlayton@redhat.com> | 2017-08-01 08:39:29 -0400 |
commit | d07a6ac7b6f878c1078b75181cdae060daac5820 (patch) | |
tree | 450c1b7ded37c327865f83358e90891f06628983 /fs/gfs2 | |
parent | 6454568d961bc5de316014548838398174a128c4 (diff) | |
download | linux-d07a6ac7b6f878c1078b75181cdae060daac5820.tar.gz linux-d07a6ac7b6f878c1078b75181cdae060daac5820.tar.bz2 linux-d07a6ac7b6f878c1078b75181cdae060daac5820.zip |
gfs2: convert to errseq_t based writeback error reporting for fsync
Also, fix a place where a writeback error might get dropped in the
gfs2_is_jdata case.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Diffstat (limited to 'fs/gfs2')
-rw-r--r-- | fs/gfs2/file.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/gfs2/file.c b/fs/gfs2/file.c index c2062a108d19..c53ac6efd04c 100644 --- a/fs/gfs2/file.c +++ b/fs/gfs2/file.c @@ -668,12 +668,14 @@ static int gfs2_fsync(struct file *file, loff_t start, loff_t end, if (ret) return ret; if (gfs2_is_jdata(ip)) - filemap_write_and_wait(mapping); + ret = file_write_and_wait(file); + if (ret) + return ret; gfs2_ail_flush(ip->i_gl, 1); } if (mapping->nrpages) - ret = filemap_fdatawait_range(mapping, start, end); + ret = file_fdatawait_range(file, start, end); return ret ? ret : ret1; } |