Home
last modified time | relevance | path

Searched refs:extent_buffer (Results 1 – 25 of 64) sorted by relevance

123

/linux-6.12.1/fs/btrfs/
Dextent_io.h93 struct extent_buffer { struct
130 struct extent_buffer *eb; argument
135 static inline unsigned long offset_in_eb_folio(const struct extent_buffer *eb, in offset_in_eb_folio()
150 static inline size_t get_eb_offset_in_folio(const struct extent_buffer *eb, in get_eb_offset_in_folio()
171 static inline unsigned long get_eb_folio_index(const struct extent_buffer *eb, in get_eb_folio_index()
254 struct extent_buffer *alloc_extent_buffer(struct btrfs_fs_info *fs_info,
256 struct extent_buffer *__alloc_dummy_extent_buffer(struct btrfs_fs_info *fs_info,
258 struct extent_buffer *alloc_dummy_extent_buffer(struct btrfs_fs_info *fs_info,
260 struct extent_buffer *btrfs_clone_extent_buffer(const struct extent_buffer *src);
261 struct extent_buffer *find_extent_buffer(struct btrfs_fs_info *fs_info,
[all …]
Dlocking.h15 struct extent_buffer;
165 void btrfs_tree_lock_nested(struct extent_buffer *eb, enum btrfs_lock_nesting nest);
167 static inline void btrfs_tree_lock(struct extent_buffer *eb) in btrfs_tree_lock()
172 void btrfs_tree_unlock(struct extent_buffer *eb);
174 void btrfs_tree_read_lock_nested(struct extent_buffer *eb, enum btrfs_lock_nesting nest);
176 static inline void btrfs_tree_read_lock(struct extent_buffer *eb) in btrfs_tree_read_lock()
181 void btrfs_tree_read_unlock(struct extent_buffer *eb);
182 int btrfs_try_tree_read_lock(struct extent_buffer *eb);
183 int btrfs_try_tree_write_lock(struct extent_buffer *eb);
184 struct extent_buffer *btrfs_lock_root_node(struct btrfs_root *root);
[all …]
Dtree-mod-log.h8 struct extent_buffer;
37 int btrfs_tree_mod_log_insert_root(struct extent_buffer *old_root,
38 struct extent_buffer *new_root,
40 int btrfs_tree_mod_log_insert_key(const struct extent_buffer *eb, int slot,
42 int btrfs_tree_mod_log_free_eb(struct extent_buffer *eb);
43 struct extent_buffer *btrfs_tree_mod_log_rewind(struct btrfs_fs_info *fs_info,
45 struct extent_buffer *eb,
47 struct extent_buffer *btrfs_get_old_root(struct btrfs_root *root, u64 time_seq);
49 int btrfs_tree_mod_log_eb_copy(struct extent_buffer *dst,
50 const struct extent_buffer *src,
[all …]
Dtree-checker.h12 struct extent_buffer;
63 enum btrfs_tree_block_status __btrfs_check_leaf(struct extent_buffer *leaf);
64 enum btrfs_tree_block_status __btrfs_check_node(struct extent_buffer *node);
66 int btrfs_check_leaf(struct extent_buffer *leaf);
67 int btrfs_check_node(struct extent_buffer *node);
69 int btrfs_check_chunk_valid(struct extent_buffer *leaf,
71 int btrfs_check_eb_owner(const struct extent_buffer *eb, u64 root_owner);
72 int btrfs_verify_level_key(struct extent_buffer *eb, int level,
Dlocking.c83 void btrfs_set_buffer_lockdep_class(u64 objectid, struct extent_buffer *eb, int level) in btrfs_set_buffer_lockdep_class()
97 void btrfs_maybe_reset_lockdep_class(struct btrfs_root *root, struct extent_buffer *eb) in btrfs_maybe_reset_lockdep_class()
107 static void btrfs_set_eb_lock_owner(struct extent_buffer *eb, pid_t owner) in btrfs_set_eb_lock_owner()
112 static void btrfs_set_eb_lock_owner(struct extent_buffer *eb, pid_t owner) { } in btrfs_set_eb_lock_owner()
139 void btrfs_tree_read_lock_nested(struct extent_buffer *eb, enum btrfs_lock_nesting nest) in btrfs_tree_read_lock_nested()
155 int btrfs_try_tree_read_lock(struct extent_buffer *eb) in btrfs_try_tree_read_lock()
169 int btrfs_try_tree_write_lock(struct extent_buffer *eb) in btrfs_try_tree_write_lock()
182 void btrfs_tree_read_unlock(struct extent_buffer *eb) in btrfs_tree_read_unlock()
196 void btrfs_tree_lock_nested(struct extent_buffer *eb, enum btrfs_lock_nesting nest) in btrfs_tree_lock_nested()
212 void btrfs_tree_unlock(struct extent_buffer *eb) in btrfs_tree_unlock()
[all …]
Dextent-tree.h11 struct extent_buffer;
100 int btrfs_get_extent_inline_ref_type(const struct extent_buffer *eb,
117 const struct extent_buffer *eb);
118 int btrfs_exclude_logged_extents(struct extent_buffer *eb);
122 struct extent_buffer *btrfs_alloc_tree_block(struct btrfs_trans_handle *trans,
132 struct extent_buffer *buf,
145 struct extent_buffer *buf, int full_backref);
147 struct extent_buffer *buf, int full_backref);
149 struct extent_buffer *eb, u64 flags);
153 struct extent_buffer *leaf, int slot);
[all …]
Daccessors.h16 struct extent_buffer;
19 struct extent_buffer *eb;
24 void btrfs_init_map_token(struct btrfs_map_token *token, struct extent_buffer *eb);
63 u##bits btrfs_get_##bits(const struct extent_buffer *eb, \
65 void btrfs_set_##bits(const struct extent_buffer *eb, void *ptr, \
74 static inline u##bits btrfs_##name(const struct extent_buffer *eb, \
80 static inline void btrfs_set_##name(const struct extent_buffer *eb, type *s, \
100 static inline u##bits btrfs_##name(const struct extent_buffer *eb) \
106 static inline void btrfs_set_##name(const struct extent_buffer *eb, \
123 static inline u64 btrfs_device_total_bytes(const struct extent_buffer *eb, in btrfs_device_total_bytes()
[all …]
Dctree.h25 struct extent_buffer;
60 struct extent_buffer *nodes[BTRFS_MAX_LEVEL];
171 struct extent_buffer *node;
173 struct extent_buffer *commit_root;
507 int btrfs_bin_search(struct extent_buffer *eb, int first_slot,
549 struct extent_buffer *btrfs_root_node(struct btrfs_root *root);
556 struct extent_buffer *btrfs_read_node_slot(struct extent_buffer *parent,
560 struct btrfs_root *root, struct extent_buffer *buf,
561 struct extent_buffer *parent, int parent_slot,
562 struct extent_buffer **cow_ret,
[all …]
Ddisk-io.h16 struct extent_buffer;
46 struct extent_buffer *read_tree_block(struct btrfs_fs_info *fs_info, u64 bytenr,
48 struct extent_buffer *btrfs_find_create_tree_block(
91 int btrfs_validate_extent_buffer(struct extent_buffer *eb,
115 struct extent_buffer *buf);
116 int btrfs_buffer_uptodate(struct extent_buffer *buf, u64 parent_transid,
118 int btrfs_read_extent_buffer(struct extent_buffer *buf,
Dctree.c35 struct extent_buffer *dst,
36 struct extent_buffer *src, int empty);
38 struct extent_buffer *dst_buf,
39 struct extent_buffer *src_buf);
57 static unsigned int leaf_data_end(const struct extent_buffer *leaf) in leaf_data_end()
79 static inline void memmove_leaf_data(const struct extent_buffer *leaf, in memmove_leaf_data()
102 static inline void copy_leaf_data(const struct extent_buffer *dst, in copy_leaf_data()
103 const struct extent_buffer *src, in copy_leaf_data()
122 static inline void memmove_leaf_items(const struct extent_buffer *leaf, in memmove_leaf_items()
142 static inline void copy_leaf_items(const struct extent_buffer *dst, in copy_leaf_items()
[all …]
Dextent_io.c41 static inline void btrfs_leak_debug_add_eb(struct extent_buffer *eb) in btrfs_leak_debug_add_eb()
51 static inline void btrfs_leak_debug_del_eb(struct extent_buffer *eb) in btrfs_leak_debug_del_eb()
63 struct extent_buffer *eb; in btrfs_extent_buffer_leak_debug_check()
77 struct extent_buffer, leak_list); in btrfs_extent_buffer_leak_debug_check()
156 sizeof(struct extent_buffer), 0, 0, in extent_buffer_init_cachep()
653 static int alloc_eb_folio_array(struct extent_buffer *eb, bool nofail) in alloc_eb_folio_array()
826 static int attach_extent_buffer_folio(struct extent_buffer *eb, in attach_extent_buffer_folio()
1484 void wait_on_extent_buffer_writeback(struct extent_buffer *eb) in wait_on_extent_buffer_writeback()
1497 static noinline_for_stack bool lock_extent_buffer_for_io(struct extent_buffer *eb, in lock_extent_buffer_for_io()
1533 static void set_btree_ioerr(struct extent_buffer *eb) in set_btree_ioerr()
[all …]
Dprint-tree.h12 struct extent_buffer;
15 void btrfs_print_leaf(const struct extent_buffer *l);
16 void btrfs_print_tree(const struct extent_buffer *c, bool follow);
Dtree-mod-log.c173 static bool tree_mod_dont_log(struct btrfs_fs_info *fs_info, const struct extent_buffer *eb) in tree_mod_dont_log()
191 const struct extent_buffer *eb) in tree_mod_need_log()
201 static struct tree_mod_elem *alloc_tree_mod_elem(const struct extent_buffer *eb, in alloc_tree_mod_elem()
224 int btrfs_tree_mod_log_insert_key(const struct extent_buffer *eb, int slot, in btrfs_tree_mod_log_insert_key()
261 static struct tree_mod_elem *tree_mod_log_alloc_move(const struct extent_buffer *eb, in tree_mod_log_alloc_move()
281 int btrfs_tree_mod_log_insert_move(const struct extent_buffer *eb, in btrfs_tree_mod_log_insert_move()
389 int btrfs_tree_mod_log_insert_root(struct extent_buffer *old_root, in btrfs_tree_mod_log_insert_root()
390 struct extent_buffer *new_root, in btrfs_tree_mod_log_insert_root()
537 int btrfs_tree_mod_log_eb_copy(struct extent_buffer *dst, in btrfs_tree_mod_log_eb_copy()
538 const struct extent_buffer *src, in btrfs_tree_mod_log_eb_copy()
[all …]
Dprint-tree.c55 static void print_chunk(const struct extent_buffer *eb, struct btrfs_chunk *chunk) in print_chunk()
68 static void print_dev_item(const struct extent_buffer *eb, in print_dev_item()
76 static void print_extent_data_ref(const struct extent_buffer *eb, in print_extent_data_ref()
86 static void print_extent_owner_ref(const struct extent_buffer *eb, in print_extent_owner_ref()
93 static void print_extent_item(const struct extent_buffer *eb, int slot, int type) in print_extent_item()
189 static void print_uuid_item(const struct extent_buffer *l, unsigned long offset, in print_uuid_item()
207 static void print_raid_stripe_key(const struct extent_buffer *eb, u32 item_size, in print_raid_stripe_key()
222 static void print_eb_refs_lock(const struct extent_buffer *eb) in print_eb_refs_lock()
230 void btrfs_print_leaf(const struct extent_buffer *l) in btrfs_print_leaf()
389 void btrfs_print_tree(const struct extent_buffer *c, bool follow) in btrfs_print_tree()
[all …]
Drelocation.h8 struct extent_buffer;
23 const struct extent_buffer *buf,
24 struct extent_buffer *cow);
Dqgroup.h16 struct extent_buffer;
354 struct extent_buffer *eb);
356 struct extent_buffer *root_eb,
438 struct extent_buffer *subvol_parent, int subvol_slot,
439 struct extent_buffer *reloc_parent, int reloc_slot,
442 struct btrfs_root *root, struct extent_buffer *eb);
Dtree-checker.c56 static void generic_err(const struct extent_buffer *eb, int slot, in generic_err()
82 static void file_extent_err(const struct extent_buffer *eb, int slot, in file_extent_err()
120 static u64 file_extent_end(struct extent_buffer *leaf, in file_extent_end()
143 static void dir_item_err(const struct extent_buffer *eb, int slot, in dir_item_err()
175 static bool check_prev_ino(struct extent_buffer *leaf, in check_prev_ino()
206 static int check_extent_data_item(struct extent_buffer *leaf, in check_extent_data_item()
364 static int check_csum_item(struct extent_buffer *leaf, struct btrfs_key *key, in check_csum_item()
410 static int check_inode_key(struct extent_buffer *leaf, struct btrfs_key *key, in check_inode_key()
462 static int check_root_key(struct extent_buffer *leaf, struct btrfs_key *key, in check_root_key()
520 static int check_dir_item(struct extent_buffer *leaf, in check_dir_item()
[all …]
Dinode-item.h10 struct extent_buffer;
112 struct btrfs_inode_ref *btrfs_find_name_in_backref(const struct extent_buffer *leaf,
116 const struct extent_buffer *leaf, int slot, u64 ref_objectid,
Daccessors.c12 static bool check_setget_bounds(const struct extent_buffer *eb, in check_setget_bounds()
28 void btrfs_init_map_token(struct btrfs_map_token *token, struct extent_buffer *eb) in btrfs_init_map_token()
91 u##bits btrfs_get_##bits(const struct extent_buffer *eb, \
148 void btrfs_set_##bits(const struct extent_buffer *eb, void *ptr, \
179 void btrfs_node_key(const struct extent_buffer *eb, in btrfs_node_key()
Droot-tree.c26 static void btrfs_read_root_item(struct extent_buffer *eb, int slot, in btrfs_read_root_item()
72 struct extent_buffer *l; in btrfs_find_root()
118 struct extent_buffer *node) in btrfs_set_root_node()
134 struct extent_buffer *l; in btrfs_update_root()
219 struct extent_buffer *leaf; in btrfs_find_orphan_roots()
350 struct extent_buffer *leaf; in btrfs_del_root_ref()
424 struct extent_buffer *leaf; in btrfs_add_root_ref()
Ddir-item.c33 struct extent_buffer *leaf; in insert_with_overflow()
67 struct extent_buffer *leaf; in btrfs_insert_xattr_item()
118 struct extent_buffer *leaf; in btrfs_insert_dir_item()
240 struct extent_buffer *leaf; in btrfs_check_dir_item_collision()
390 struct extent_buffer *leaf; in btrfs_match_dir_item_name()
423 struct extent_buffer *leaf; in btrfs_delete_one_dir_name()
Dbackref.h136 const struct extent_buffer *leaf, void *user_ctx);
220 int tree_backref_for_extent(unsigned long *ptr, struct extent_buffer *eb,
239 struct extent_buffer *eb_in, u64 parent,
335 struct extent_buffer *eb;
Droot-tree.h9 struct extent_buffer;
38 struct extent_buffer *node);
Dinode-item.c17 struct btrfs_inode_ref *btrfs_find_name_in_backref(const struct extent_buffer *leaf, in btrfs_find_name_in_backref()
45 const struct extent_buffer *leaf, int slot, u64 ref_objectid, in btrfs_find_name_in_ext_backref()
115 struct extent_buffer *leaf; in btrfs_del_inode_extref()
184 struct extent_buffer *leaf; in btrfs_del_inode_ref()
265 struct extent_buffer *leaf; in btrfs_insert_inode_extref()
408 struct extent_buffer *leaf; in btrfs_lookup_inode()
427 const struct extent_buffer *leaf, in btrfs_trace_truncate()
464 struct extent_buffer *leaf; in btrfs_truncate_inode_items()
/linux-6.12.1/fs/btrfs/tests/
Dextent-io-tests.c342 static int check_eb_bitmap(unsigned long *bitmap, struct extent_buffer *eb) in check_eb_bitmap()
384 struct extent_buffer *eb, in test_bitmap_set()
399 struct extent_buffer *eb, in test_bitmap_clear()
412 static int __test_eb_bitmaps(unsigned long *bitmap, struct extent_buffer *eb) in __test_eb_bitmaps()
510 struct extent_buffer *eb = NULL; in test_eb_bitmaps()
671 static void dump_eb_and_memory_contents(struct extent_buffer *eb, void *memory, in dump_eb_and_memory_contents()
687 static int verify_eb_and_memory(struct extent_buffer *eb, void *memory, in verify_eb_and_memory()
705 static void init_eb_and_memory(struct extent_buffer *eb, void *memory) in init_eb_and_memory()
714 struct extent_buffer *eb = NULL; in test_eb_mem_ops()

123