/linux/fs/bcachefs/ |
H A D | btree_iter.h | 9 void bch2_trans_updates_to_text(struct printbuf *, struct btree_trans *); 10 void bch2_btree_path_to_text(struct printbuf *, struct btree_trans *, btree_path_idx_t); 11 void bch2_trans_paths_to_text(struct printbuf *, struct btree_trans *); 12 void bch2_dump_trans_updates(struct btree_trans *); 13 void bch2_dump_trans_paths_updates(struct btree_trans *); 22 static inline void __btree_path_get(struct btree_trans *trans, struct btree_path *path, bool intent) in __btree_path_get() 38 static inline bool __btree_path_put(struct btree_trans *trans, struct btree_path *path, bool intent) in __btree_path_put() 76 void __bch2_btree_trans_sort_paths(struct btree_trans *); 78 static inline void btree_trans_sort_paths(struct btree_trans *trans) in btree_trans_sort_paths() 103 __trans_next_path(struct btree_trans *trans, unsigned *idx) in __trans_next_path() [all …]
|
H A D | btree_locking.h | 18 void bch2_trans_unlock_noassert(struct btree_trans *); 19 void bch2_trans_unlock_write(struct btree_trans *); 26 static inline struct btree_transaction_stats *btree_trans_stats(struct btree_trans *trans) in btree_trans_stats() 79 static inline void mark_btree_node_locked(struct btree_trans *trans, in mark_btree_node_locked() 109 static void btree_trans_lock_hold_time_update(struct btree_trans *trans, in btree_trans_lock_hold_time_update() 121 void bch2_btree_node_unlock_write(struct btree_trans *, 124 static inline void btree_node_unlock(struct btree_trans *trans, in btree_node_unlock() 152 static inline void __bch2_btree_path_unlock(struct btree_trans *trans, in __bch2_btree_path_unlock() 166 __bch2_btree_node_unlock_write(struct btree_trans *trans, struct btree *b) in __bch2_btree_node_unlock_write() 180 bch2_btree_node_unlock_write_inlined(struct btree_trans *trans, struct btree_path *path, in bch2_btree_node_unlock_write_inlined() [all …]
|
H A D | inode.h | 20 int __bch2_inode_has_child_snapshots(struct btree_trans *, struct bpos); 22 static inline int bch2_inode_has_child_snapshots(struct btree_trans *trans, struct bpos pos) in bch2_inode_has_child_snapshots() 29 int bch2_trigger_inode(struct btree_trans *, enum btree_id, unsigned, 116 struct bkey_i *bch2_inode_to_v3(struct btree_trans *, struct bkey_i *); 120 int __bch2_inode_peek(struct btree_trans *, struct btree_iter *, 123 static inline int bch2_inode_peek_nowarn(struct btree_trans *trans, in bch2_inode_peek_nowarn() 131 static inline int bch2_inode_peek(struct btree_trans *trans, in bch2_inode_peek() 141 int bch2_inode_write_flags(struct btree_trans *, struct btree_iter *, 144 static inline int bch2_inode_write(struct btree_trans *trans, in bch2_inode_write() 151 int __bch2_fsck_write_inode(struct btree_trans *, struct bch_inode_unpacked *); [all …]
|
H A D | btree_locking.c | 19 struct six_lock_count bch2_btree_node_lock_counts(struct btree_trans *trans, in bch2_btree_node_lock_counts() 46 void bch2_btree_node_unlock_write(struct btree_trans *trans, in bch2_btree_node_unlock_write() 58 struct btree_trans *trans; 119 static void __lock_graph_down(struct lock_graph *g, struct btree_trans *trans) in __lock_graph_down() 128 static void lock_graph_down(struct lock_graph *g, struct btree_trans *trans) in lock_graph_down() 154 static void trace_would_deadlock(struct lock_graph *g, struct btree_trans *trans) in trace_would_deadlock() 183 static int btree_trans_abort_preference(struct btree_trans *trans) in btree_trans_abort_preference() 226 struct btree_trans *trans = i->trans; in break_cycle() 251 static int lock_graph_descend(struct lock_graph *g, struct btree_trans *trans, in lock_graph_descend() 254 struct btree_trans *orig_trans = g->g->trans; in lock_graph_descend() [all …]
|
H A D | trace.h | 52 TP_PROTO(struct btree_trans *trans, unsigned long caller_ip, const char *str), 75 TP_PROTO(struct btree_trans *trans, const char *str), 121 TP_PROTO(struct btree_trans *trans, struct btree *b), 162 DECLARE_EVENT_CLASS(btree_trans, 163 TP_PROTO(struct btree_trans *trans), 462 DEFINE_EVENT(btree_trans, btree_cache_cannibalize_lock_fail, 463 TP_PROTO(struct btree_trans *trans), 467 DEFINE_EVENT(btree_trans, btree_cache_cannibalize_lock, 468 TP_PROTO(struct btree_trans *trans), 472 DEFINE_EVENT(btree_trans, btree_cache_cannibalize, [all …]
|
H A D | subvolume.h | 14 int bch2_subvolume_trigger(struct btree_trans *, enum btree_id, unsigned, 25 int bch2_subvol_has_children(struct btree_trans *, u32); 26 int bch2_subvolume_get(struct btree_trans *, unsigned, 28 int __bch2_subvolume_get_snapshot(struct btree_trans *, u32, 30 int bch2_subvolume_get_snapshot(struct btree_trans *, u32, u32 *); 32 int bch2_subvol_is_ro_trans(struct btree_trans *, u32); 83 int bch2_subvolume_unlink(struct btree_trans *, u32); 84 int bch2_subvolume_create(struct btree_trans *, u64, u32, u32, u32 *, u32 *, bool);
|
H A D | dirent.h | 34 int bch2_dirent_read_target(struct btree_trans *, subvol_inum, 44 int bch2_dirent_create_snapshot(struct btree_trans *, u32, u64, u32, 48 int bch2_dirent_create(struct btree_trans *, subvol_inum, 64 int bch2_dirent_rename(struct btree_trans *, 71 int bch2_dirent_lookup_trans(struct btree_trans *, struct btree_iter *, 78 int bch2_empty_dir_snapshot(struct btree_trans *, u64, u32, u32); 79 int bch2_empty_dir_trans(struct btree_trans *, subvol_inum);
|
H A D | fs-common.h | 14 int bch2_create_trans(struct btree_trans *, subvol_inum, 23 int bch2_link_trans(struct btree_trans *, 28 int bch2_unlink_trans(struct btree_trans *, subvol_inum, 33 int bch2_rename_trans(struct btree_trans *, 45 int bch2_inum_to_path(struct btree_trans *, subvol_inum, struct printbuf *);
|
H A D | btree_update_interior.h | 13 int bch2_btree_node_check_topology(struct btree_trans *, struct btree *); 126 struct btree_trans *, 130 int bch2_btree_split_leaf(struct btree_trans *, btree_path_idx_t, unsigned); 132 int bch2_btree_increase_depth(struct btree_trans *, btree_path_idx_t, unsigned); 134 int __bch2_foreground_maybe_merge(struct btree_trans *, btree_path_idx_t, 137 static inline int bch2_foreground_maybe_merge_sibling(struct btree_trans *trans, in bch2_foreground_maybe_merge_sibling() 157 static inline int bch2_foreground_maybe_merge(struct btree_trans *trans, in bch2_foreground_maybe_merge() 170 int bch2_btree_node_rewrite(struct btree_trans *, struct btree_iter *, 173 int bch2_btree_node_update_key(struct btree_trans *, struct btree_iter *, 176 int bch2_btree_node_update_key_get_iter(struct btree_trans *, struct btree *, [all …]
|
H A D | btree_cache.h | 27 void bch2_btree_node_update_key_early(struct btree_trans *, enum btree_id, unsigned, 30 void bch2_btree_cache_cannibalize_unlock(struct btree_trans *); 31 int bch2_btree_cache_cannibalize_lock(struct btree_trans *, struct closure *); 34 struct btree *bch2_btree_node_mem_alloc(struct btree_trans *, bool); 36 struct btree *bch2_btree_node_get(struct btree_trans *, struct btree_path *, 40 struct btree *bch2_btree_node_get_noiter(struct btree_trans *, const struct bkey_i *, 43 int bch2_btree_node_prefetch(struct btree_trans *, struct btree_path *, 46 void bch2_btree_node_evict(struct btree_trans *, const struct bkey_i *);
|
H A D | btree_iter.c | 24 static inline void btree_path_list_remove(struct btree_trans *, struct btree_path *); 25 static inline void btree_path_list_add(struct btree_trans *, 37 static btree_path_idx_t btree_path_alloc(struct btree_trans *, btree_path_idx_t); 38 static void bch2_trans_srcu_lock(struct btree_trans *); 121 static void bch2_btree_path_verify_cached(struct btree_trans *trans, in bch2_btree_path_verify_cached() 138 static void bch2_btree_path_verify_level(struct btree_trans *trans, in bch2_btree_path_verify_level() 220 static void bch2_btree_path_verify(struct btree_trans *trans, in bch2_btree_path_verify() 238 void bch2_trans_verify_paths(struct btree_trans *trans) in bch2_trans_verify_paths() 249 struct btree_trans *trans = iter->trans; in bch2_btree_iter_verify() 281 struct btree_trans *trans = iter->trans; in bch2_btree_iter_verify_ret() [all …]
|
H A D | snapshot.h | 15 struct bkey_i_snapshot_tree *__bch2_snapshot_tree_create(struct btree_trans *); 17 int bch2_snapshot_tree_lookup(struct btree_trans *, u32, struct bch_snapshot_tree *); 22 int bch2_mark_snapshot(struct btree_trans *, enum btree_id, unsigned, 231 int bch2_snapshot_lookup(struct btree_trans *trans, u32 id, 233 int bch2_snapshot_get_subvol(struct btree_trans *, u32, 237 int bch2_snapshot_node_create(struct btree_trans *, u32, 243 int bch2_check_key_has_snapshot(struct btree_trans *, struct btree_iter *, struct bkey_s_c); 245 int bch2_snapshot_node_set_deleted(struct btree_trans *, u32); 248 int __bch2_key_has_snapshot_overwrites(struct btree_trans *, enum btree_id, struct bpos); 250 static inline int bch2_key_has_snapshot_overwrites(struct btree_trans *trans, in bch2_key_has_snapshot_overwrites()
|
H A D | io_misc.h | 5 int bch2_extent_fallocate(struct btree_trans *, subvol_inum, struct btree_iter *, 8 int bch2_fpunch_at(struct btree_trans *, struct btree_iter *, 19 int bch2_resume_logged_op_truncate(struct btree_trans *, struct bkey_i *); 30 int bch2_resume_logged_op_finsert(struct btree_trans *, struct bkey_i *);
|
H A D | btree_update.c | 27 bch2_trans_update_by_path(struct btree_trans *, btree_path_idx_t, 31 static noinline int extent_front_merge(struct btree_trans *trans, in extent_front_merge() 67 static noinline int extent_back_merge(struct btree_trans *trans, in extent_back_merge() 93 static int need_whiteout_for_snapshot(struct btree_trans *trans, in need_whiteout_for_snapshot() 123 int __bch2_insert_snapshot_whiteouts(struct btree_trans *trans, in __bch2_insert_snapshot_whiteouts() 186 int bch2_trans_update_extent_overwrite(struct btree_trans *trans, in bch2_trans_update_extent_overwrite() 285 static int bch2_trans_update_extent(struct btree_trans *trans, in bch2_trans_update_extent() 347 static noinline int flush_new_cached_update(struct btree_trans *trans, in flush_new_cached_update() 385 bch2_trans_update_by_path(struct btree_trans *trans, btree_path_idx_t path_idx, in bch2_trans_update_by_path() 471 static noinline int bch2_trans_update_get_key_cache(struct btree_trans *trans, in bch2_trans_update_get_key_cache() [all …]
|
H A D | acl.h | 33 int bch2_set_acl_trans(struct btree_trans *, subvol_inum, 37 int bch2_acl_chmod(struct btree_trans *, subvol_inum, 43 static inline int bch2_set_acl_trans(struct btree_trans *trans, subvol_inum inum, in bch2_set_acl_trans() 50 static inline int bch2_acl_chmod(struct btree_trans *trans, subvol_inum inum, in bch2_acl_chmod()
|
H A D | btree_trans_commit.c | 44 static void verify_update_old_key(struct btree_trans *trans, struct btree_insert_entry *i) in verify_update_old_key() 67 static inline struct btree_path_level *insert_l(struct btree_trans *trans, struct btree_insert_entr… in insert_l() 72 static inline bool same_leaf_as_prev(struct btree_trans *trans, in same_leaf_as_prev() 79 static inline bool same_leaf_as_next(struct btree_trans *trans, in same_leaf_as_next() 86 inline void bch2_btree_node_prep_for_write(struct btree_trans *trans, in bch2_btree_node_prep_for_write() 104 static noinline int trans_lock_write_fail(struct btree_trans *trans, struct btree_insert_entry *i) in trans_lock_write_fail() 117 static inline int bch2_trans_lock_write(struct btree_trans *trans) in bch2_trans_lock_write() 136 static inline void bch2_trans_unlock_updates_write(struct btree_trans *trans) in bch2_trans_unlock_updates_write() 151 bool bch2_btree_bset_insert_key(struct btree_trans *trans, in bch2_btree_bset_insert_key() 232 struct btree_trans *trans = bch2_trans_get(c); in __btree_node_flush() [all …]
|
H A D | btree_journal_iter.h | 20 struct btree_trans *trans; 61 int bch2_btree_and_journal_iter_prefetch(struct btree_trans *, struct btree_path *, 70 bool bch2_key_deleted_in_journal(struct btree_trans *, enum btree_id, unsigned, struct bpos); 77 void __bch2_btree_and_journal_iter_init_node_iter(struct btree_trans *, 80 void bch2_btree_and_journal_iter_init_node_iter(struct btree_trans *,
|
H A D | subvolume.c | 14 static int bch2_subvolume_delete(struct btree_trans *, u32); 27 static int check_subvol(struct btree_trans *trans, in check_subvol() 172 static int check_subvol_child(struct btree_trans *trans, in check_subvol_child() 246 static int subvolume_children_mod(struct btree_trans *trans, struct bpos pos, bool set) in subvolume_children_mod() 253 int bch2_subvolume_trigger(struct btree_trans *trans, in bch2_subvolume_trigger() 273 int bch2_subvol_has_children(struct btree_trans *trans, u32 subvol) in bch2_subvol_has_children() 287 bch2_subvolume_get_inlined(struct btree_trans *trans, unsigned subvol, in bch2_subvolume_get_inlined() 300 int bch2_subvolume_get(struct btree_trans *trans, unsigned subvol, in bch2_subvolume_get() 307 int bch2_subvol_is_ro_trans(struct btree_trans *trans, u32 subvol) in bch2_subvol_is_ro_trans() 324 int bch2_snapshot_get_subvol(struct btree_trans *trans, u32 snapshot, in bch2_snapshot_get_subvol() [all …]
|
H A D | str_hash.h | 152 bch2_hash_lookup_in_snapshot(struct btree_trans *trans, in bch2_hash_lookup_in_snapshot() 183 bch2_hash_lookup(struct btree_trans *trans, in bch2_hash_lookup() 199 bch2_hash_hole(struct btree_trans *trans, in bch2_hash_hole() 225 int bch2_hash_needs_whiteout(struct btree_trans *trans, in bch2_hash_needs_whiteout() 255 struct bkey_s_c bch2_hash_set_or_get_in_snapshot(struct btree_trans *trans, in bch2_hash_set_or_get_in_snapshot() 315 int bch2_hash_set_in_snapshot(struct btree_trans *trans, in bch2_hash_set_in_snapshot() 337 int bch2_hash_set(struct btree_trans *trans, in bch2_hash_set() 353 int bch2_hash_delete_at(struct btree_trans *trans, in bch2_hash_delete_at() 379 int bch2_hash_delete(struct btree_trans *trans, in bch2_hash_delete() 397 int __bch2_str_hash_check_key(struct btree_trans *, [all …]
|
H A D | lru.h | 47 int bch2_lru_del(struct btree_trans *, u16, u64, u64); 48 int bch2_lru_set(struct btree_trans *, u16, u64, u64); 49 int bch2_lru_change(struct btree_trans *, u16, u64, u64, u64); 52 int bch2_lru_check_set(struct btree_trans *, u16, u64, struct bkey_s_c, struct bkey_buf *);
|
H A D | logged_ops.c | 13 int (*resume)(struct btree_trans *, struct bkey_i *); 33 static int resume_logged_op(struct btree_trans *trans, struct btree_iter *iter, in resume_logged_op() 76 static int __bch2_logged_op_start(struct btree_trans *trans, struct bkey_i *k) in __bch2_logged_op_start() 91 int bch2_logged_op_start(struct btree_trans *trans, struct bkey_i *k) in bch2_logged_op_start() 97 int bch2_logged_op_finish(struct btree_trans *trans, struct bkey_i *k) in bch2_logged_op_finish()
|
H A D | btree_write_buffer.h | 22 struct btree_trans; 23 int bch2_btree_write_buffer_flush_sync(struct btree_trans *); 25 int bch2_btree_write_buffer_flush_nocheck_rw(struct btree_trans *); 26 int bch2_btree_write_buffer_tryflush(struct btree_trans *); 29 int bch2_btree_write_buffer_maybe_flush(struct btree_trans *, struct bkey_s_c, struct bkey_buf *);
|
H A D | logged_ops.h | 11 static inline int bch2_logged_op_update(struct btree_trans *trans, struct bkey_i *op) in bch2_logged_op_update() 17 int bch2_logged_op_start(struct btree_trans *, struct bkey_i *); 18 int bch2_logged_op_finish(struct btree_trans *, struct bkey_i *);
|
H A D | reflink.h | 9 int bch2_trigger_reflink_p(struct btree_trans *, enum btree_id, unsigned, 24 int bch2_trigger_reflink_v(struct btree_trans *, enum btree_id, unsigned, 40 int bch2_trigger_indirect_inline_data(struct btree_trans *, 76 struct bkey_s_c bch2_lookup_indirect_extent(struct btree_trans *, struct btree_iter *,
|
H A D | bkey_methods.h | 9 struct btree_trans; 31 int (*trigger)(struct btree_trans *, enum btree_id, unsigned, 80 static inline int bch2_key_trigger(struct btree_trans *trans, in bch2_key_trigger() 92 static inline int bch2_key_trigger_old(struct btree_trans *trans, in bch2_key_trigger_old() 106 static inline int bch2_key_trigger_new(struct btree_trans *trans, in bch2_key_trigger_new()
|