diff options
author | Dave Chinner <dchinner@redhat.com> | 2011-04-21 09:34:28 +0000 |
---|---|---|
committer | Alex Elder <aelder@sgi.com> | 2011-05-19 12:03:48 -0500 |
commit | bf59170a66bc3eaf3ee513aa6ce9774aa2ab5188 (patch) | |
tree | aae7b19e61ea88cddf4ba5508ef971c767f15b4d /fs/xfs/xfs_quota.h | |
parent | 44396476a0f24e5174768d3732f1958857c26d22 (diff) | |
download | kernel_samsung_smdk4412-bf59170a66bc3eaf3ee513aa6ce9774aa2ab5188.tar.gz kernel_samsung_smdk4412-bf59170a66bc3eaf3ee513aa6ce9774aa2ab5188.tar.bz2 kernel_samsung_smdk4412-bf59170a66bc3eaf3ee513aa6ce9774aa2ab5188.zip |
xfs: obey minleft values during extent allocation correctly
When allocating an extent that is long enough to consume the
remaining free space in an AG, we need to ensure that the allocation
leaves enough space in the AG for any subsequent bmap btree blocks
that are needed to track the new extent. These have to be allocated
in the same AG as we only reserve enough blocks in an allocation
transaction for modification of the freespace trees in a single AG.
xfs_alloc_fix_minleft() has been considering blocks on the AGFL as
free blocks available for extent and bmbt block allocation, which is
not correct - blocks on the AGFL are there exclusively for the use
of the free space btrees. As a result, when minleft is less than the
number of blocks on the AGFL, xfs_alloc_fix_minleft() does not trim
the given extent to leave minleft blocks available for bmbt
allocation, and hence we can fail allocation during bmbt record
insertion.
Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Alex Elder <aelder@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_quota.h')
0 files changed, 0 insertions, 0 deletions