Lines Matching refs:upper
208 while (!list_empty(&node->upper)) { in walk_up_backref()
209 edge = list_first_entry(&node->upper, struct btrfs_backref_edge, in walk_up_backref()
232 if (list_is_last(&edge->list[LOWER], &lower->upper)) { in walk_down_backref()
351 ASSERT(list_empty(&cur->upper)); in handle_useless_nodes()
369 if (list_empty(&lower->upper)) in handle_useless_nodes()
2136 if (list_empty(&next->upper)) in calcu_metadata_size()
2139 edge = list_first_entry(&next->upper, struct btrfs_backref_edge, in calcu_metadata_size()
2208 struct btrfs_backref_node *upper; in do_relocation() local
2226 list_for_each_entry(edge, &node->upper, list[LOWER]) { in do_relocation()
2229 upper = edge->node[UPPER]; in do_relocation()
2230 root = select_reloc_root(trans, rc, upper, edges); in do_relocation()
2236 if (upper->eb && !upper->locked) { in do_relocation()
2238 ret = btrfs_bin_search(upper->eb, 0, key, &slot); in do_relocation()
2242 bytenr = btrfs_node_blockptr(upper->eb, slot); in do_relocation()
2246 btrfs_backref_drop_node_buffer(upper); in do_relocation()
2249 if (!upper->eb) { in do_relocation()
2259 if (!upper->eb) { in do_relocation()
2260 upper->eb = path->nodes[upper->level]; in do_relocation()
2261 path->nodes[upper->level] = NULL; in do_relocation()
2263 BUG_ON(upper->eb != path->nodes[upper->level]); in do_relocation()
2266 upper->locked = 1; in do_relocation()
2267 path->locks[upper->level] = 0; in do_relocation()
2269 slot = path->slots[upper->level]; in do_relocation()
2272 ret = btrfs_bin_search(upper->eb, 0, key, &slot); in do_relocation()
2278 bytenr = btrfs_node_blockptr(upper->eb, slot); in do_relocation()
2284 upper->eb->start); in do_relocation()
2294 eb = btrfs_read_node_slot(upper->eb, slot); in do_relocation()
2302 ret = btrfs_cow_block(trans, root, eb, upper->eb, in do_relocation()
2318 .parent = upper->eb->start, in do_relocation()
2319 .owning_root = btrfs_header_owner(upper->eb), in do_relocation()
2320 .ref_root = btrfs_header_owner(upper->eb), in do_relocation()
2323 btrfs_set_node_blockptr(upper->eb, slot, in do_relocation()
2325 btrfs_set_node_ptr_generation(upper->eb, slot, in do_relocation()
2327 btrfs_mark_buffer_dirty(trans, upper->eb); in do_relocation()
2334 upper->eb); in do_relocation()
2339 if (!upper->pending) in do_relocation()
2340 btrfs_backref_drop_node_buffer(upper); in do_relocation()
2342 btrfs_backref_unlock_node_buffer(upper); in do_relocation()
2422 if (list_empty(&next->upper)) in update_processed_blocks()
2425 edge = list_first_entry(&next->upper, struct btrfs_backref_edge, in update_processed_blocks()