xfs: add a xfs_iext_update_extent helper
authorChristoph Hellwig <hch@lst.de>
Tue, 29 Aug 2017 22:44:11 +0000 (15:44 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Fri, 1 Sep 2017 17:55:30 +0000 (10:55 -0700)
commit67e4e69cb2a7afbffdefd1a0a23a94d1d706c38f
tree51db8bbd69d9af10e792896e72be40ebd510f5f6
parentd522d569d6adf72ceda90153a086e089e6c2fbc6
xfs: add a xfs_iext_update_extent helper

This helper is used to update an extent record based on the extent index,
and can be used to provide a level of abstractions between callers that
want to modify in-core extent records and the details of the extent list
implementation.

Also switch all users of the xfs_bmbt_set_all(xfs_iext_get_ext(...))
pattern to this new helper.

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>
fs/xfs/libxfs/xfs_bmap.c
fs/xfs/libxfs/xfs_inode_fork.c
fs/xfs/libxfs/xfs_inode_fork.h