]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: convert COW blocks to real blocks before unwritten extent conversion
authorChristoph Hellwig <hch@lst.de>
Mon, 10 Oct 2016 22:03:19 +0000 (09:03 +1100)
committerDave Chinner <david@fromorbit.com>
Mon, 10 Oct 2016 22:03:19 +0000 (09:03 +1100)
commit055e32389a95d1756079a2ce69dd9cf7f26dd4a9
tree6633916ccfd93027c9d595f57d2b7fc411069430
parent6a5196fda2287865d71fbf7a714aa1ce3ca996ad
xfs: convert COW blocks to real blocks before unwritten extent conversion

We need to splice COW blocks we've completed in xfs_end_io_direct_write
into the data fork before converting unwritten extents.  Otherwise
xfs_bmapi_write might first allocate blocks for any holes in the data
fork, which isn't only not needed but also harmful as it might cause
reserved block underruns in the transaction.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
fs/xfs/xfs_aops.c