Lines Matching refs:leaf
208 struct extent_buffer *leaf; in btrfs_find_orphan_roots() local
232 leaf = path->nodes[0]; in btrfs_find_orphan_roots()
233 if (path->slots[0] >= btrfs_header_nritems(leaf)) { in btrfs_find_orphan_roots()
239 leaf = path->nodes[0]; in btrfs_find_orphan_roots()
242 btrfs_item_key_to_cpu(leaf, &key, path->slots[0]); in btrfs_find_orphan_roots()
322 struct extent_buffer *leaf; in btrfs_del_root_ref() local
340 leaf = path->nodes[0]; in btrfs_del_root_ref()
341 ref = btrfs_item_ptr(leaf, path->slots[0], in btrfs_del_root_ref()
344 if ((btrfs_root_ref_dirid(leaf, ref) != dirid) || in btrfs_del_root_ref()
345 (btrfs_root_ref_name_len(leaf, ref) != name_len) || in btrfs_del_root_ref()
346 memcmp_extent_buffer(leaf, name, ptr, name_len)) { in btrfs_del_root_ref()
350 *sequence = btrfs_root_ref_sequence(leaf, ref); in btrfs_del_root_ref()
397 struct extent_buffer *leaf; in btrfs_add_root_ref() local
416 leaf = path->nodes[0]; in btrfs_add_root_ref()
417 ref = btrfs_item_ptr(leaf, path->slots[0], struct btrfs_root_ref); in btrfs_add_root_ref()
418 btrfs_set_root_ref_dirid(leaf, ref, dirid); in btrfs_add_root_ref()
419 btrfs_set_root_ref_sequence(leaf, ref, sequence); in btrfs_add_root_ref()
420 btrfs_set_root_ref_name_len(leaf, ref, name_len); in btrfs_add_root_ref()
422 write_extent_buffer(leaf, name, ptr, name_len); in btrfs_add_root_ref()
423 btrfs_mark_buffer_dirty(leaf); in btrfs_add_root_ref()