Commit 95eacf0f authored by Dave Chinner's avatar Dave Chinner Committed by Ben Myers

xfs: remove xfs_wait_on_pages()

It's just a simple wrapper around a VFS function that is only called
by another function in xfs_fs_subr.c. Remove it and call the VFS
function directly.
Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
Reviewed-by: default avatarAndrew Dahl <adahl@sgi.com>
Signed-off-by: default avatarBen Myers <bpm@sgi.com>
parent d6638ae2
...@@ -62,23 +62,9 @@ xfs_flush_pages( ...@@ -62,23 +62,9 @@ xfs_flush_pages(
last == -1 ? LLONG_MAX : last); last == -1 ? LLONG_MAX : last);
if (flags & XBF_ASYNC) if (flags & XBF_ASYNC)
return ret; return ret;
ret2 = xfs_wait_on_pages(ip, first, last); ret2 = -filemap_fdatawait_range(mapping, first,
last == -1 ? XFS_ISIZE(ip) - 1 : last);
if (!ret) if (!ret)
ret = ret2; ret = ret2;
return ret; return ret;
} }
int
xfs_wait_on_pages(
xfs_inode_t *ip,
xfs_off_t first,
xfs_off_t last)
{
struct address_space *mapping = VFS_I(ip)->i_mapping;
if (mapping_tagged(mapping, PAGECACHE_TAG_WRITEBACK)) {
return -filemap_fdatawait_range(mapping, first,
last == -1 ? XFS_ISIZE(ip) - 1 : last);
}
return 0;
}
...@@ -52,7 +52,6 @@ int xfs_flushinval_pages(struct xfs_inode *ip, xfs_off_t first, ...@@ -52,7 +52,6 @@ int xfs_flushinval_pages(struct xfs_inode *ip, xfs_off_t first,
xfs_off_t last, int fiopt); xfs_off_t last, int fiopt);
int xfs_flush_pages(struct xfs_inode *ip, xfs_off_t first, int xfs_flush_pages(struct xfs_inode *ip, xfs_off_t first,
xfs_off_t last, uint64_t flags, int fiopt); xfs_off_t last, uint64_t flags, int fiopt);
int xfs_wait_on_pages(struct xfs_inode *ip, xfs_off_t first, xfs_off_t last);
int xfs_zero_eof(struct xfs_inode *, xfs_off_t, xfs_fsize_t); int xfs_zero_eof(struct xfs_inode *, xfs_off_t, xfs_fsize_t);
int xfs_free_eofblocks(struct xfs_mount *, struct xfs_inode *, bool); int xfs_free_eofblocks(struct xfs_mount *, struct xfs_inode *, bool);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment