aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/libxfs/xfs_refcount_btree.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/libxfs/xfs_refcount_btree.c')
-rw-r--r--fs/xfs/libxfs/xfs_refcount_btree.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_refcount_btree.c b/fs/xfs/libxfs/xfs_refcount_btree.c
index 6f47ab876d90..5d9de9b21726 100644
--- a/fs/xfs/libxfs/xfs_refcount_btree.c
+++ b/fs/xfs/libxfs/xfs_refcount_btree.c
@@ -427,6 +427,15 @@ xfs_refcountbt_calc_reserves(
427 tree_len = be32_to_cpu(agf->agf_refcount_blocks); 427 tree_len = be32_to_cpu(agf->agf_refcount_blocks);
428 xfs_trans_brelse(tp, agbp); 428 xfs_trans_brelse(tp, agbp);
429 429
430 /*
431 * The log is permanently allocated, so the space it occupies will
432 * never be available for the kinds of things that would require btree
433 * expansion. We therefore can pretend the space isn't there.
434 */
435 if (mp->m_sb.sb_logstart &&
436 XFS_FSB_TO_AGNO(mp, mp->m_sb.sb_logstart) == agno)
437 agblocks -= mp->m_sb.sb_logblocks;
438
430 *ask += xfs_refcountbt_max_size(mp, agblocks); 439 *ask += xfs_refcountbt_max_size(mp, agblocks);
431 *used += tree_len; 440 *used += tree_len;
432 441