|
@@ -676,6 +676,8 @@ struct backref_node *build_backref_tree(struct reloc_control *rc,
|
|
|
err = -ENOMEM;
|
|
|
goto out;
|
|
|
}
|
|
|
+ path1->reada = 1;
|
|
|
+ path2->reada = 2;
|
|
|
|
|
|
node = alloc_backref_node(cache);
|
|
|
if (!node) {
|
|
@@ -1996,6 +1998,7 @@ static noinline_for_stack int merge_reloc_root(struct reloc_control *rc,
|
|
|
path = btrfs_alloc_path();
|
|
|
if (!path)
|
|
|
return -ENOMEM;
|
|
|
+ path->reada = 1;
|
|
|
|
|
|
reloc_root = root->reloc_root;
|
|
|
root_item = &reloc_root->root_item;
|
|
@@ -3297,6 +3300,7 @@ static int find_data_references(struct reloc_control *rc,
|
|
|
path = btrfs_alloc_path();
|
|
|
if (!path)
|
|
|
return -ENOMEM;
|
|
|
+ path->reada = 1;
|
|
|
|
|
|
root = read_fs_root(rc->extent_root->fs_info, ref_root);
|
|
|
if (IS_ERR(root)) {
|
|
@@ -3665,6 +3669,7 @@ static noinline_for_stack int relocate_block_group(struct reloc_control *rc)
|
|
|
path = btrfs_alloc_path();
|
|
|
if (!path)
|
|
|
return -ENOMEM;
|
|
|
+ path->reada = 1;
|
|
|
|
|
|
ret = prepare_to_relocate(rc);
|
|
|
if (ret) {
|
|
@@ -4090,6 +4095,7 @@ int btrfs_recover_relocation(struct btrfs_root *root)
|
|
|
path = btrfs_alloc_path();
|
|
|
if (!path)
|
|
|
return -ENOMEM;
|
|
|
+ path->reada = -1;
|
|
|
|
|
|
key.objectid = BTRFS_TREE_RELOC_OBJECTID;
|
|
|
key.type = BTRFS_ROOT_ITEM_KEY;
|