summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/extent-tree.c
diff options
context:
space:
mode:
authorChris Mason2007-05-10 17:24:42 +0200
committerDavid Woodhouse2007-05-10 17:24:42 +0200
commit8d7be552a733e53135a91d2d28f57ab87dc0e889 (patch)
tree62126fc82875b81f0132392f1d1833ceb960e1fb /fs/btrfs/extent-tree.c
parentBtrfs: many allocator fixes, pretty solid (diff)
downloadkernel-qcow2-linux-8d7be552a733e53135a91d2d28f57ab87dc0e889.tar.gz
kernel-qcow2-linux-8d7be552a733e53135a91d2d28f57ab87dc0e889.tar.xz
kernel-qcow2-linux-8d7be552a733e53135a91d2d28f57ab87dc0e889.zip
Btrfs: fix check_node and check_leaf to use less cpu
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/extent-tree.c')
-rw-r--r--fs/btrfs/extent-tree.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index 3ac9da453472..1497ff98f0d3 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -235,7 +235,7 @@ struct btrfs_block_group_cache *btrfs_find_block_group(struct btrfs_root *root,
hint->key.offset - 1,
BTRFS_BLOCK_GROUP_AVAIL);
}
- last = hint->key.offset * 2;
+ last = hint->key.offset * 3;
if (hint->key.objectid >= last)
last = max(search_start + hint->key.offset - 1,
hint->key.objectid - last);
@@ -554,8 +554,8 @@ static int update_block_group(struct btrfs_trans_handle *trans,
blocknr + i);
}
}
- if (old_val < (cache->key.offset * 8) / 10 &&
- old_val + num >= (cache->key.offset * 8) / 10) {
+ if (old_val < (cache->key.offset * 6) / 10 &&
+ old_val + num >= (cache->key.offset * 6) / 10) {
printk("group %Lu now available\n", cache->key.objectid);
radix_tree_tag_set(cache->radix,
cache->key.objectid +