Hi all, this series adds the always_cow mode support after improving our COW write support a little bit first. Note that I'm mostly reposting this to get visibility for the core fixes and improvements. The actual always COW patch, which is last in the series still has outstanding feedback I need to address. The always_cow mode stresses the COW path a lot, but with a few xfstests fixups it generall looks good, except for a few tests that complain about fragmentation, which is rather inherent in this mode, and xfs/326 which inserts error tags into the COW path not getting the expected result. Changes since v3: - spelling fixes - improve argument naming and add a comment in xfs_reflink_allocate_cow - trace the COW imap if allocating COW blocks - collect a few reviewed-by tags from Darrick Changes since v2: - add a patch to remove xfs_trim_extent_eof - add a patch to remove the separate io_type and rely on existing state in the writeback path - rework the truncate race handling in the writeback path a little more Changes since v1: - make delalloc and unwritten extent conversions simpler and more robust - add a few additional cleanups - support all fallocate modes but actual preallocation - rebase on top of a fix from Brian (which is included as first patch to make the patch set more usable)