aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_bmap_btree.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_bmap_btree.c')
-rw-r--r--fs/xfs/xfs_bmap_btree.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/fs/xfs/xfs_bmap_btree.c b/fs/xfs/xfs_bmap_btree.c
index 1ec494e111b5..519249e20536 100644
--- a/fs/xfs/xfs_bmap_btree.c
+++ b/fs/xfs/xfs_bmap_btree.c
@@ -1721,8 +1721,9 @@ xfs_bmbt_decrement(
1721 XFS_BMBT_TRACE_CURSOR(cur, ENTRY); 1721 XFS_BMBT_TRACE_CURSOR(cur, ENTRY);
1722 XFS_BMBT_TRACE_ARGI(cur, level); 1722 XFS_BMBT_TRACE_ARGI(cur, level);
1723 ASSERT(level < cur->bc_nlevels); 1723 ASSERT(level < cur->bc_nlevels);
1724 if (level < cur->bc_nlevels - 1) 1724
1725 xfs_btree_readahead(cur, level, XFS_BTCUR_LEFTRA); 1725 xfs_btree_readahead(cur, level, XFS_BTCUR_LEFTRA);
1726
1726 if (--cur->bc_ptrs[level] > 0) { 1727 if (--cur->bc_ptrs[level] > 0) {
1727 XFS_BMBT_TRACE_CURSOR(cur, EXIT); 1728 XFS_BMBT_TRACE_CURSOR(cur, EXIT);
1728 *stat = 1; 1729 *stat = 1;
@@ -1743,8 +1744,7 @@ xfs_bmbt_decrement(
1743 for (lev = level + 1; lev < cur->bc_nlevels; lev++) { 1744 for (lev = level + 1; lev < cur->bc_nlevels; lev++) {
1744 if (--cur->bc_ptrs[lev] > 0) 1745 if (--cur->bc_ptrs[lev] > 0)
1745 break; 1746 break;
1746 if (lev < cur->bc_nlevels - 1) 1747 xfs_btree_readahead(cur, lev, XFS_BTCUR_LEFTRA);
1747 xfs_btree_readahead(cur, lev, XFS_BTCUR_LEFTRA);
1748 } 1748 }
1749 if (lev == cur->bc_nlevels) { 1749 if (lev == cur->bc_nlevels) {
1750 XFS_BMBT_TRACE_CURSOR(cur, EXIT); 1750 XFS_BMBT_TRACE_CURSOR(cur, EXIT);
@@ -1995,8 +1995,8 @@ xfs_bmbt_increment(
1995 XFS_BMBT_TRACE_CURSOR(cur, ENTRY); 1995 XFS_BMBT_TRACE_CURSOR(cur, ENTRY);
1996 XFS_BMBT_TRACE_ARGI(cur, level); 1996 XFS_BMBT_TRACE_ARGI(cur, level);
1997 ASSERT(level < cur->bc_nlevels); 1997 ASSERT(level < cur->bc_nlevels);
1998 if (level < cur->bc_nlevels - 1) 1998
1999 xfs_btree_readahead(cur, level, XFS_BTCUR_RIGHTRA); 1999 xfs_btree_readahead(cur, level, XFS_BTCUR_RIGHTRA);
2000 block = xfs_bmbt_get_block(cur, level, &bp); 2000 block = xfs_bmbt_get_block(cur, level, &bp);
2001#ifdef DEBUG 2001#ifdef DEBUG
2002 if ((error = xfs_btree_check_lblock(cur, block, level, bp))) { 2002 if ((error = xfs_btree_check_lblock(cur, block, level, bp))) {
@@ -2024,8 +2024,7 @@ xfs_bmbt_increment(
2024#endif 2024#endif
2025 if (++cur->bc_ptrs[lev] <= be16_to_cpu(block->bb_numrecs)) 2025 if (++cur->bc_ptrs[lev] <= be16_to_cpu(block->bb_numrecs))
2026 break; 2026 break;
2027 if (lev < cur->bc_nlevels - 1) 2027 xfs_btree_readahead(cur, lev, XFS_BTCUR_RIGHTRA);
2028 xfs_btree_readahead(cur, lev, XFS_BTCUR_RIGHTRA);
2029 } 2028 }
2030 if (lev == cur->bc_nlevels) { 2029 if (lev == cur->bc_nlevels) {
2031 XFS_BMBT_TRACE_CURSOR(cur, EXIT); 2030 XFS_BMBT_TRACE_CURSOR(cur, EXIT);