Lines Matching refs:subvol_path
169 struct btrfs_path *subvol_path; member
193 if (wc->subvol_path && wc->subvol_path->nodes[0]) { in do_abort_log_replay()
197 btrfs_print_leaf(wc->subvol_path->nodes[0]); in do_abort_log_replay()
511 ret = btrfs_search_slot(NULL, root, &wc->log_key, wc->subvol_path, 0, 0); in overwrite_item()
520 dst_eb = wc->subvol_path->nodes[0]; in overwrite_item()
521 dst_slot = wc->subvol_path->slots[0]; in overwrite_item()
531 btrfs_release_path(wc->subvol_path); in overwrite_item()
553 btrfs_release_path(wc->subvol_path); in overwrite_item()
603 btrfs_release_path(wc->subvol_path); in overwrite_item()
605 wc->subvol_path->skip_release_on_error = true; in overwrite_item()
606 ret = btrfs_insert_empty_item(trans, root, wc->subvol_path, &wc->log_key, item_size); in overwrite_item()
607 wc->subvol_path->skip_release_on_error = false; in overwrite_item()
609 dst_eb = wc->subvol_path->nodes[0]; in overwrite_item()
610 dst_slot = wc->subvol_path->slots[0]; in overwrite_item()
617 btrfs_truncate_item(trans, wc->subvol_path, item_size, 1); in overwrite_item()
619 btrfs_extend_item(trans, wc->subvol_path, item_size - found_size); in overwrite_item()
686 btrfs_release_path(wc->subvol_path); in overwrite_item()
771 ret = btrfs_lookup_file_extent(trans, root, wc->subvol_path, in replay_one_extent()
777 struct extent_buffer *leaf = wc->subvol_path->nodes[0]; in replay_one_extent()
781 ptr = btrfs_item_ptr_offset(leaf, wc->subvol_path->slots[0]); in replay_one_extent()
790 btrfs_release_path(wc->subvol_path); in replay_one_extent()
794 btrfs_release_path(wc->subvol_path); in replay_one_extent()
800 drop_args.path = wc->subvol_path; in replay_one_extent()
828 ret = btrfs_insert_empty_item(trans, root, wc->subvol_path, in replay_one_extent()
837 dest_offset = btrfs_item_ptr_offset(wc->subvol_path->nodes[0], in replay_one_extent()
838 wc->subvol_path->slots[0]); in replay_one_extent()
839 copy_extent_buffer(wc->subvol_path->nodes[0], wc->log_leaf, dest_offset, in replay_one_extent()
849 btrfs_release_path(wc->subvol_path); in replay_one_extent()
917 btrfs_release_path(wc->subvol_path); in replay_one_extent()
1089 struct extent_buffer *leaf = wc->subvol_path->nodes[0]; in drop_one_dir_item()
1102 btrfs_release_path(wc->subvol_path); in drop_one_dir_item()
1214 struct extent_buffer *leaf = wc->subvol_path->nodes[0]; in unlink_refs_not_in_log()
1223 ptr = btrfs_item_ptr_offset(leaf, wc->subvol_path->slots[0]); in unlink_refs_not_in_log()
1224 ptr_end = ptr + btrfs_item_size(leaf, wc->subvol_path->slots[0]); in unlink_refs_not_in_log()
1259 btrfs_release_path(wc->subvol_path); in unlink_refs_not_in_log()
1276 struct extent_buffer *leaf = wc->subvol_path->nodes[0]; in unlink_extrefs_not_in_log()
1277 const unsigned long base = btrfs_item_ptr_offset(leaf, wc->subvol_path->slots[0]); in unlink_extrefs_not_in_log()
1278 const u32 item_size = btrfs_item_size(leaf, wc->subvol_path->slots[0]); in unlink_extrefs_not_in_log()
1326 btrfs_release_path(wc->subvol_path); in unlink_extrefs_not_in_log()
1355 ret = btrfs_search_slot(NULL, root, &search_key, wc->subvol_path, 0, 0); in __add_inode_ref()
1376 btrfs_release_path(wc->subvol_path); in __add_inode_ref()
1379 extref = btrfs_lookup_inode_extref(root, wc->subvol_path, name, in __add_inode_ref()
1390 btrfs_release_path(wc->subvol_path); in __add_inode_ref()
1393 di = btrfs_lookup_dir_index_item(trans, root, wc->subvol_path, btrfs_ino(dir), in __add_inode_ref()
1407 btrfs_release_path(wc->subvol_path); in __add_inode_ref()
1410 di = btrfs_lookup_dir_item(trans, root, wc->subvol_path, btrfs_ino(dir), name, 0); in __add_inode_ref()
1423 btrfs_release_path(wc->subvol_path); in __add_inode_ref()
1485 btrfs_release_path(wc->subvol_path); in unlink_old_inode_refs()
1486 ret = btrfs_search_slot(NULL, root, &wc->log_key, wc->subvol_path, 0, 0); in unlink_old_inode_refs()
1499 eb = wc->subvol_path->nodes[0]; in unlink_old_inode_refs()
1500 ref_ptr = btrfs_item_ptr_offset(eb, wc->subvol_path->slots[0]); in unlink_old_inode_refs()
1501 ref_end = ref_ptr + btrfs_item_size(eb, wc->subvol_path->slots[0]); in unlink_old_inode_refs()
1538 btrfs_release_path(wc->subvol_path); in unlink_old_inode_refs()
1565 btrfs_release_path(wc->subvol_path); in unlink_old_inode_refs()
1689 ret = inode_in_dir(root, wc->subvol_path, btrfs_ino(dir), in add_inode_ref()
1761 btrfs_release_path(wc->subvol_path); in add_inode_ref()
1888 ret = count_inode_refs(inode, wc->subvol_path); in fixup_inode_link_count()
1894 ret = count_inode_extrefs(inode, wc->subvol_path); in fixup_inode_link_count()
1923 btrfs_release_path(wc->subvol_path); in fixup_inode_link_count()
1940 ret = btrfs_search_slot(trans, root, &key, wc->subvol_path, -1, 1); in fixup_inode_link_counts()
1946 if (wc->subvol_path->slots[0] == 0) in fixup_inode_link_counts()
1948 wc->subvol_path->slots[0]--; in fixup_inode_link_counts()
1951 btrfs_item_key_to_cpu(wc->subvol_path->nodes[0], &key, wc->subvol_path->slots[0]); in fixup_inode_link_counts()
1956 ret = btrfs_del_item(trans, root, wc->subvol_path); in fixup_inode_link_counts()
1960 btrfs_release_path(wc->subvol_path); in fixup_inode_link_counts()
1979 btrfs_release_path(wc->subvol_path); in fixup_inode_link_counts()
2012 ret = btrfs_insert_empty_item(trans, root, wc->subvol_path, &key, 0); in link_to_fixup_dir()
2014 btrfs_release_path(wc->subvol_path); in link_to_fixup_dir()
2080 btrfs_dir_item_key_to_cpu(wc->subvol_path->nodes[0], dst_di, &found_key); in delete_conflicting_dir_entry()
2085 btrfs_dir_flags(wc->subvol_path->nodes[0], dst_di) == log_flags) in delete_conflicting_dir_entry()
2152 ret = btrfs_lookup_inode(trans, root, wc->subvol_path, &log_key, 0); in replay_one_name()
2153 btrfs_release_path(wc->subvol_path); in replay_one_name()
2163 dir_dst_di = btrfs_lookup_dir_item(trans, root, wc->subvol_path, in replay_one_name()
2185 btrfs_release_path(wc->subvol_path); in replay_one_name()
2187 index_dst_di = btrfs_lookup_dir_index_item(trans, root, wc->subvol_path, in replay_one_name()
2210 btrfs_release_path(wc->subvol_path); in replay_one_name()
2447 eb = wc->subvol_path->nodes[0]; in check_item_in_log()
2448 slot = wc->subvol_path->slots[0]; in check_item_in_log()
2481 btrfs_release_path(wc->subvol_path); in check_item_in_log()
2505 btrfs_release_path(wc->subvol_path); in check_item_in_log()
2534 ret = btrfs_search_slot(NULL, root, &search_key, wc->subvol_path, 0, 0); in replay_xattr_deletes()
2542 nritems = btrfs_header_nritems(wc->subvol_path->nodes[0]); in replay_xattr_deletes()
2543 for (int i = wc->subvol_path->slots[0]; i < nritems; i++) { in replay_xattr_deletes()
2550 btrfs_item_key_to_cpu(wc->subvol_path->nodes[0], &key, i); in replay_xattr_deletes()
2556 di = btrfs_item_ptr(wc->subvol_path->nodes[0], i, struct btrfs_dir_item); in replay_xattr_deletes()
2557 total_size = btrfs_item_size(wc->subvol_path->nodes[0], i); in replay_xattr_deletes()
2560 u16 name_len = btrfs_dir_name_len(wc->subvol_path->nodes[0], di); in replay_xattr_deletes()
2561 u16 data_len = btrfs_dir_data_len(wc->subvol_path->nodes[0], di); in replay_xattr_deletes()
2573 read_extent_buffer(wc->subvol_path->nodes[0], name, in replay_xattr_deletes()
2581 btrfs_release_path(wc->subvol_path); in replay_xattr_deletes()
2582 di = btrfs_lookup_xattr(trans, root, wc->subvol_path, ino, in replay_xattr_deletes()
2595 wc->subvol_path, di); in replay_xattr_deletes()
2604 btrfs_release_path(wc->subvol_path); in replay_xattr_deletes()
2623 ret = btrfs_next_leaf(root, wc->subvol_path); in replay_xattr_deletes()
2633 btrfs_release_path(wc->subvol_path); in replay_xattr_deletes()
2691 ret = find_dir_range(log, wc->subvol_path, dirid, in replay_dir_deletes()
2707 wc->subvol_path, 0, 0); in replay_dir_deletes()
2716 nritems = btrfs_header_nritems(wc->subvol_path->nodes[0]); in replay_dir_deletes()
2717 if (wc->subvol_path->slots[0] >= nritems) { in replay_dir_deletes()
2718 ret = btrfs_next_leaf(root, wc->subvol_path); in replay_dir_deletes()
2728 btrfs_item_key_to_cpu(wc->subvol_path->nodes[0], &found_key, in replay_dir_deletes()
2729 wc->subvol_path->slots[0]); in replay_dir_deletes()
2746 btrfs_release_path(wc->subvol_path); in replay_dir_deletes()
2753 btrfs_release_path(wc->subvol_path); in replay_dir_deletes()
2797 ASSERT(wc->subvol_path == NULL); in replay_one_buffer()
2798 wc->subvol_path = btrfs_alloc_path(); in replay_one_buffer()
2799 if (!wc->subvol_path) { in replay_one_buffer()
2887 drop_args.path = wc->subvol_path; in replay_one_buffer()
2951 btrfs_free_path(wc->subvol_path); in replay_one_buffer()
2952 wc->subvol_path = NULL; in replay_one_buffer()
7791 wc.subvol_path = path; in btrfs_recover_log_trees()
7793 wc.subvol_path = NULL; in btrfs_recover_log_trees()