]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
xfs: fix reflink quota reservation accounting error
authorDarrick J. Wong <darrick.wong@oracle.com>
Mon, 29 Jun 2020 21:47:18 +0000 (14:47 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 19 Aug 2020 06:23:52 +0000 (08:23 +0200)
commit526b5288e9529c1ff678f298021ce0c0ea827a0b
tree21db07644f39a252560fce380fb9bb4c0db2d596
parent427f3f5f76add5174584f52d656a2faaf7a24367
xfs: fix reflink quota reservation accounting error

[ Upstream commit 83895227aba1ade33e81f586aa7b6b1e143096a5 ]

Quota reservations are supposed to account for the blocks that might be
allocated due to a bmap btree split.  Reflink doesn't do this, so fix
this to make the quota accounting more accurate before we start
rearranging things.

Fixes: 862bb360ef56 ("xfs: reflink extents from one file to another")
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/xfs/xfs_reflink.c