]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: set IOMAP_F_NEW more carefully
authorChristoph Hellwig <hch@lst.de>
Thu, 17 Oct 2019 20:12:04 +0000 (13:12 -0700)
committerDarrick J. Wong <darrick.wong@oracle.com>
Mon, 21 Oct 2019 15:51:59 +0000 (08:51 -0700)
commit72d0c39d71262df7ca480d783c671fac1b76c25d
treefb6976b8f97659e26f26de6a85dc46e3bf930c72
parentba92fcadab4709e8ae6b95ea39305d39344096e5
xfs: set IOMAP_F_NEW more carefully

Don't set IOMAP_F_NEW if we COW over an existing allocated range, as
these aren't strictly new allocations.  This is required to be able to
use IOMAP_F_NEW to zero newly allocated blocks, which is required for
the iomap code to fully support file systems that don't do delayed
allocations or use unwritten extents.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
fs/xfs/xfs_iomap.c