Lines Matching refs:em_tree
1518 struct extent_map_tree *em_tree; in find_next_chunk() local
1523 em_tree = &fs_info->mapping_tree.map_tree; in find_next_chunk()
1524 read_lock(&em_tree->lock); in find_next_chunk()
1525 n = rb_last(&em_tree->map); in find_next_chunk()
1530 read_unlock(&em_tree->lock); in find_next_chunk()
2731 struct extent_map_tree *em_tree; in btrfs_remove_chunk() local
2741 em_tree = &root->fs_info->mapping_tree.map_tree; in btrfs_remove_chunk()
2743 read_lock(&em_tree->lock); in btrfs_remove_chunk()
2744 em = lookup_extent_mapping(em_tree, chunk_offset, 1); in btrfs_remove_chunk()
2745 read_unlock(&em_tree->lock); in btrfs_remove_chunk()
4493 struct extent_map_tree *em_tree; in __btrfs_alloc_chunk() local
4730 em_tree = &extent_root->fs_info->mapping_tree.map_tree; in __btrfs_alloc_chunk()
4731 write_lock(&em_tree->lock); in __btrfs_alloc_chunk()
4732 ret = add_extent_mapping(em_tree, em, 0); in __btrfs_alloc_chunk()
4737 write_unlock(&em_tree->lock); in __btrfs_alloc_chunk()
4766 write_lock(&em_tree->lock); in __btrfs_alloc_chunk()
4767 remove_extent_mapping(em_tree, em); in __btrfs_alloc_chunk()
4768 write_unlock(&em_tree->lock); in __btrfs_alloc_chunk()
4790 struct extent_map_tree *em_tree; in btrfs_finish_chunk_alloc() local
4799 em_tree = &extent_root->fs_info->mapping_tree.map_tree; in btrfs_finish_chunk_alloc()
4800 read_lock(&em_tree->lock); in btrfs_finish_chunk_alloc()
4801 em = lookup_extent_mapping(em_tree, chunk_offset, chunk_size); in btrfs_finish_chunk_alloc()
4802 read_unlock(&em_tree->lock); in btrfs_finish_chunk_alloc()
5014 struct extent_map_tree *em_tree = &map_tree->map_tree; in btrfs_num_copies() local
5017 read_lock(&em_tree->lock); in btrfs_num_copies()
5018 em = lookup_extent_mapping(em_tree, logical, len); in btrfs_num_copies()
5019 read_unlock(&em_tree->lock); in btrfs_num_copies()
5067 struct extent_map_tree *em_tree = &map_tree->map_tree; in btrfs_full_stripe_len() local
5070 read_lock(&em_tree->lock); in btrfs_full_stripe_len()
5071 em = lookup_extent_mapping(em_tree, logical, len); in btrfs_full_stripe_len()
5072 read_unlock(&em_tree->lock); in btrfs_full_stripe_len()
5088 struct extent_map_tree *em_tree = &map_tree->map_tree; in btrfs_is_parity_mirror() local
5091 read_lock(&em_tree->lock); in btrfs_is_parity_mirror()
5092 em = lookup_extent_mapping(em_tree, logical, len); in btrfs_is_parity_mirror()
5093 read_unlock(&em_tree->lock); in btrfs_is_parity_mirror()
5216 struct extent_map_tree *em_tree = &map_tree->map_tree; in __btrfs_map_block() local
5238 read_lock(&em_tree->lock); in __btrfs_map_block()
5239 em = lookup_extent_mapping(em_tree, logical, *length); in __btrfs_map_block()
5240 read_unlock(&em_tree->lock); in __btrfs_map_block()
5772 struct extent_map_tree *em_tree = &map_tree->map_tree; in btrfs_rmap_block() local
5782 read_lock(&em_tree->lock); in btrfs_rmap_block()
5783 em = lookup_extent_mapping(em_tree, chunk_start, 1); in btrfs_rmap_block()
5784 read_unlock(&em_tree->lock); in btrfs_rmap_block()