summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_bmap_util.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2018-03-13 23:15:32 -0700
committerDarrick J. Wong <darrick.wong@oracle.com>2018-03-15 10:31:38 -0700
commitf5c54717bf2b9e052bb69d6ee19fe22e87817079 (patch)
tree85180b0cccbbd36f387de72e662507592191b808 /fs/xfs/xfs_bmap_util.c
parentc7dbe3f2c41969845b8ea000fc5e025d4987a8fb (diff)
downloadlinux-f5c54717bf2b9e052bb69d6ee19fe22e87817079.tar.gz
linux-f5c54717bf2b9e052bb69d6ee19fe22e87817079.tar.bz2
linux-f5c54717bf2b9e052bb69d6ee19fe22e87817079.zip
xfs: remove xfs_zero_range
This helper doesn't add any real value over just calling iomap_zero_range directly, so remove it. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'fs/xfs/xfs_bmap_util.c')
-rw-r--r--fs/xfs/xfs_bmap_util.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/fs/xfs/xfs_bmap_util.c b/fs/xfs/xfs_bmap_util.c
index 19ea7d086cf8..05dee8fdd895 100644
--- a/fs/xfs/xfs_bmap_util.c
+++ b/fs/xfs/xfs_bmap_util.c
@@ -1208,18 +1208,15 @@ xfs_free_file_space(
/*
* Now that we've unmap all full blocks we'll have to zero out any
- * partial block at the beginning and/or end. xfs_zero_range is
- * smart enough to skip any holes, including those we just created,
- * but we must take care not to zero beyond EOF and enlarge i_size.
+ * partial block at the beginning and/or end. iomap_zero_range is smart
+ * enough to skip any holes, including those we just created, but we
+ * must take care not to zero beyond EOF and enlarge i_size.
*/
-
if (offset >= XFS_ISIZE(ip))
return 0;
-
if (offset + len > XFS_ISIZE(ip))
len = XFS_ISIZE(ip) - offset;
-
- return xfs_zero_range(ip, offset, len, NULL);
+ return iomap_zero_range(VFS_I(ip), offset, len, NULL, &xfs_iomap_ops);
}
/*