]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: simplify the xfs_iomap_write_direct calling
authorChristoph Hellwig <hch@lst.de>
Wed, 30 Oct 2019 19:24:59 +0000 (12:24 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Sun, 3 Nov 2019 18:22:30 +0000 (10:22 -0800)
commit7e39920d3b683d4105c8815bb975c663ad3c791d
tree89b73dd4b10dddb2198ff318f86b7264a697caf0
parent93c97b9f8c08aebbbe2197648acaf39eef564525
xfs: simplify the xfs_iomap_write_direct calling

Move the EOF alignment and checking for the next allocated extent into
the callers to avoid the need to pass the byte based offset and count
as well as looking at the incoming imap.  The added benefit is that
the caller can unlock the incoming ilock and the function doesn't have
funny unbalanced locking contexts.

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/xfs_iomap.c
fs/xfs/xfs_iomap.h
fs/xfs/xfs_pnfs.c