Lines Matching refs:nodes
202 * nodes from multiple log transactions to do sequential
410 u32 dst_size = btrfs_item_size(path->nodes[0],
430 dst_ptr = btrfs_item_ptr_offset(path->nodes[0], path->slots[0]);
431 read_extent_buffer(path->nodes[0], dst_copy, dst_ptr,
457 item = btrfs_item_ptr(path->nodes[0], path->slots[0],
459 nbytes = btrfs_inode_nbytes(path->nodes[0], item);
504 found_size = btrfs_item_size(path->nodes[0],
513 dst_ptr = btrfs_item_ptr_offset(path->nodes[0],
533 struct extent_buffer *dst_eb = path->nodes[0];
551 S_ISDIR(btrfs_inode_mode(path->nodes[0], dst_item))) {
553 saved_i_size = btrfs_inode_size(path->nodes[0],
558 copy_extent_buffer(path->nodes[0], eb, dst_ptr,
564 btrfs_set_inode_size(path->nodes[0], dst_item, saved_i_size);
571 if (btrfs_inode_generation(path->nodes[0], dst_item) == 0) {
572 btrfs_set_inode_generation(path->nodes[0], dst_item,
577 btrfs_mark_buffer_dirty(trans, path->nodes[0]);
687 leaf = path->nodes[0];
729 dest_offset = btrfs_item_ptr_offset(path->nodes[0],
731 copy_extent_buffer(path->nodes[0], eb, dest_offset,
938 leaf = path->nodes[0];
986 btrfs_dir_item_key_to_cpu(path->nodes[0], di, &location);
999 btrfs_dir_item_key_to_cpu(path->nodes[0], di, &location);
1039 ret = !!btrfs_find_name_in_ext_backref(path->nodes[0],
1043 ret = !!btrfs_find_name_in_backref(path->nodes[0],
1076 leaf = path->nodes[0];
1135 leaf = path->nodes[0];
1286 eb = path->nodes[0];
1506 leaf = path->nodes[0];
1555 btrfs_item_key_to_cpu(path->nodes[0], &key,
1560 ptr = btrfs_item_ptr_offset(path->nodes[0], path->slots[0]);
1561 ptr_end = ptr + btrfs_item_size(path->nodes[0],
1567 name_len = btrfs_inode_ref_name_len(path->nodes[0],
1672 btrfs_item_key_to_cpu(path->nodes[0], &key, path->slots[0]);
1789 btrfs_dir_item_key_to_cpu(path->nodes[0], dst_di, &found_key);
1794 btrfs_dir_flags(path->nodes[0], dst_di) == log_flags)
2049 btrfs_item_key_to_cpu(path->nodes[0], &key, path->slots[0]);
2055 item = btrfs_item_ptr(path->nodes[0], path->slots[0],
2057 found_end = btrfs_dir_log_end(path->nodes[0], item);
2068 nritems = btrfs_header_nritems(path->nodes[0]);
2076 btrfs_item_key_to_cpu(path->nodes[0], &key, path->slots[0]);
2082 item = btrfs_item_ptr(path->nodes[0], path->slots[0],
2084 found_end = btrfs_dir_log_end(path->nodes[0], item);
2122 eb = path->nodes[0];
2198 nritems = btrfs_header_nritems(path->nodes[0]);
2206 btrfs_item_key_to_cpu(path->nodes[0], &key, i);
2212 di = btrfs_item_ptr(path->nodes[0], i, struct btrfs_dir_item);
2213 total_size = btrfs_item_size(path->nodes[0], i);
2216 u16 name_len = btrfs_dir_name_len(path->nodes[0], di);
2217 u16 data_len = btrfs_dir_data_len(path->nodes[0], di);
2226 read_extent_buffer(path->nodes[0], name,
2334 nritems = btrfs_header_nritems(path->nodes[0]);
2342 btrfs_item_key_to_cpu(path->nodes[0], &found_key,
2603 cur = path->nodes[*level];
2655 if (path->nodes[*level-1])
2656 free_extent_buffer(path->nodes[*level-1]);
2657 path->nodes[*level-1] = next;
2662 path->slots[*level] = btrfs_header_nritems(path->nodes[*level]);
2677 for (i = *level; i < BTRFS_MAX_LEVEL - 1 && path->nodes[i]; i++) {
2679 if (slot + 1 < btrfs_header_nritems(path->nodes[i])) {
2685 ret = wc->process_func(root, path->nodes[*level], wc,
2686 btrfs_header_generation(path->nodes[*level]),
2692 ret = clean_log_buffer(trans, path->nodes[*level]);
2696 free_extent_buffer(path->nodes[*level]);
2697 path->nodes[*level] = NULL;
2724 path->nodes[level] = log->node;
2747 if (path->nodes[orig_level]) {
2748 ret = wc->process_func(log, path->nodes[orig_level], wc,
2749 btrfs_header_generation(path->nodes[orig_level]),
2754 ret = clean_log_buffer(trans, path->nodes[orig_level]);
3519 item = btrfs_item_ptr(path->nodes[0], path->slots[0],
3522 const u64 curr_end = btrfs_dir_log_end(path->nodes[0], item);
3532 btrfs_set_dir_log_end(path->nodes[0], item, last_offset);
3533 btrfs_mark_buffer_dirty(trans, path->nodes[0]);
3594 dst = dst_path->nodes[0];
3639 const int nritems = btrfs_header_nritems(path->nodes[0]);
3651 src = btrfs_clone_extent_buffer(path->nodes[0]);
3657 path->nodes[0] = src;
3795 btrfs_item_key_to_cpu(path->nodes[0], &tmp,
3811 btrfs_item_key_to_cpu(path->nodes[0], &tmp, path->slots[0]);
3867 path->slots[0] = btrfs_header_nritems(path->nodes[0]);
3881 btrfs_item_key_to_cpu(path->nodes[0], &min_key, path->slots[0]);
3886 if (btrfs_header_generation(path->nodes[0]) != trans->transid) {
3984 btrfs_item_key_to_cpu(path->nodes[0], &key, path->slots[0] - 1);
4067 btrfs_item_key_to_cpu(path->nodes[0], &found_key,
4075 ret = btrfs_bin_search(path->nodes[0], 0, &found_key, &start_slot);
4211 inode_item = btrfs_item_ptr(path->nodes[0], path->slots[0],
4213 fill_inode_item(trans, path->nodes[0], inode_item, &inode->vfs_inode,
4290 * creates a nasty lock dependency when COWing log tree nodes/leaves:
4313 src = btrfs_clone_extent_buffer(src_path->nodes[0]);
4319 src_path->nodes[0] = src;
4471 dst_offset = btrfs_item_ptr_offset(dst_path->nodes[0], dst_slot);
4477 inode_item = btrfs_item_ptr(dst_path->nodes[0], dst_slot,
4479 fill_inode_item(trans, dst_path->nodes[0], inode_item,
4484 copy_extent_buffer(dst_path->nodes[0], src, dst_offset,
4491 btrfs_mark_buffer_dirty(trans, dst_path->nodes[0]);
4692 leaf = path->nodes[0];
4753 leaf = path->nodes[0];
4773 leaf = path->nodes[0];
4955 item = btrfs_item_ptr(path->nodes[0], path->slots[0],
4957 *size_ret = btrfs_inode_size(path->nodes[0], item);
5012 struct extent_buffer *leaf = path->nodes[0];
5088 struct extent_buffer *leaf = path->nodes[0];
5090 if (path->slots[0] >= btrfs_header_nritems(path->nodes[0])) {
5098 leaf = path->nodes[0];
5133 leaf = path->nodes[0];
5265 btrfs_dir_item_key_to_cpu(search_path->nodes[0],
5412 struct extent_buffer *leaf = path->nodes[0];
5559 item = btrfs_item_ptr(path->nodes[0], path->slots[0],
5561 if (S_ISDIR(btrfs_inode_mode(path->nodes[0], item)))
5841 ret = btrfs_check_ref_name_override(path->nodes[0],
5899 if (path->slots[0] < btrfs_header_nritems(path->nodes[0])) {
5900 btrfs_item_key_to_cpu(path->nodes[0], min_key,
5965 data_ptr = btrfs_item_ptr(path->nodes[0], path->slots[0], char);
5966 write_extent_buffer(path->nodes[0], &curr->data,
6125 struct extent_buffer *leaf = path->nodes[0];
6687 struct extent_buffer *leaf = path->nodes[0];
6791 btrfs_item_key_to_cpu(path->nodes[0], &found_key, path->slots[0]);
6829 leaf = path->nodes[0];
6837 leaf = path->nodes[0];
6920 struct extent_buffer *leaf = path->nodes[0];
7177 btrfs_item_key_to_cpu(path->nodes[0], &found_key,