Home
last modified time | relevance | path

Searched refs:bch_fs (Results 1 – 25 of 150) sorted by relevance

123456

/linux-6.12.1/fs/bcachefs/
Dsuper.h13 struct bch_fs *bch2_dev_to_fs(dev_t);
14 struct bch_fs *bch2_uuid_to_fs(__uuid_t);
16 bool bch2_dev_state_allowed(struct bch_fs *, struct bch_dev *,
18 int __bch2_dev_set_state(struct bch_fs *, struct bch_dev *,
20 int bch2_dev_set_state(struct bch_fs *, struct bch_dev *,
24 int bch2_dev_remove(struct bch_fs *, struct bch_dev *, int);
25 int bch2_dev_add(struct bch_fs *, const char *);
26 int bch2_dev_online(struct bch_fs *, const char *);
27 int bch2_dev_offline(struct bch_fs *, struct bch_dev *, int);
28 int bch2_dev_resize(struct bch_fs *, struct bch_dev *, u64);
[all …]
Dalloc_foreground.h14 struct bch_fs;
19 void bch2_reset_alloc_cursors(struct bch_fs *);
26 struct dev_alloc_list bch2_dev_alloc_list(struct bch_fs *,
33 static inline struct bch_dev *ob_dev(struct bch_fs *c, struct open_bucket *ob) in ob_dev()
38 struct open_bucket *bch2_bucket_alloc(struct bch_fs *, struct bch_dev *,
42 static inline void ob_push(struct bch_fs *c, struct open_buckets *obs, in ob_push()
56 static inline struct open_bucket *ec_open_bucket(struct bch_fs *c, in ec_open_bucket()
69 void bch2_open_bucket_write_error(struct bch_fs *,
72 void __bch2_open_bucket_put(struct bch_fs *, struct open_bucket *);
74 static inline void bch2_open_bucket_put(struct bch_fs *c, struct open_bucket *ob) in bch2_open_bucket_put()
[all …]
Dsnapshot.h7 void bch2_snapshot_tree_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
8 int bch2_snapshot_tree_validate(struct bch_fs *, struct bkey_s_c,
21 void bch2_snapshot_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
22 int bch2_snapshot_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
43 static inline const struct snapshot_t *snapshot_t(struct bch_fs *c, u32 id) in snapshot_t()
48 static inline u32 bch2_snapshot_tree(struct bch_fs *c, u32 id) in bch2_snapshot_tree()
58 static inline u32 __bch2_snapshot_parent_early(struct bch_fs *c, u32 id) in __bch2_snapshot_parent_early()
64 static inline u32 bch2_snapshot_parent_early(struct bch_fs *c, u32 id) in bch2_snapshot_parent_early()
73 static inline u32 __bch2_snapshot_parent(struct bch_fs *c, u32 id) in __bch2_snapshot_parent()
90 static inline u32 bch2_snapshot_parent(struct bch_fs *c, u32 id) in bch2_snapshot_parent()
[all …]
Dfsck.h5 int bch2_check_inodes(struct bch_fs *);
6 int bch2_check_extents(struct bch_fs *);
7 int bch2_check_indirect_extents(struct bch_fs *);
8 int bch2_check_dirents(struct bch_fs *);
9 int bch2_check_xattrs(struct bch_fs *);
10 int bch2_check_root(struct bch_fs *);
11 int bch2_check_subvolume_structure(struct bch_fs *);
12 int bch2_check_unreachable_inodes(struct bch_fs *);
13 int bch2_check_directory_structure(struct bch_fs *);
14 int bch2_check_nlinks(struct bch_fs *);
[all …]
Dquota.h11 int bch2_quota_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
12 void bch2_quota_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
29 static inline unsigned enabled_qtypes(struct bch_fs *c) in enabled_qtypes()
38 int bch2_quota_acct(struct bch_fs *, struct bch_qid, enum quota_counters,
41 int bch2_quota_transfer(struct bch_fs *, unsigned, struct bch_qid,
44 void bch2_fs_quota_exit(struct bch_fs *);
45 void bch2_fs_quota_init(struct bch_fs *);
46 int bch2_fs_quota_read(struct bch_fs *);
52 static inline int bch2_quota_acct(struct bch_fs *c, struct bch_qid qid, in bch2_quota_acct()
59 static inline int bch2_quota_transfer(struct bch_fs *c, unsigned qtypes, in bch2_quota_transfer()
[all …]
Dec.h11 int bch2_stripe_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
12 void bch2_stripe_to_text(struct printbuf *, struct bch_fs *,
158 struct bch_fs *c;
214 void *bch2_writepoint_ec_buf(struct bch_fs *, struct write_point *);
216 void bch2_ec_bucket_cancel(struct bch_fs *, struct open_bucket *);
218 int bch2_ec_stripe_new_alloc(struct bch_fs *, struct ec_stripe_head *);
220 void bch2_ec_stripe_head_put(struct bch_fs *, struct ec_stripe_head *);
225 void bch2_stripes_heap_update(struct bch_fs *, struct stripe *, size_t);
226 void bch2_stripes_heap_del(struct bch_fs *, struct stripe *, size_t);
227 void bch2_stripes_heap_insert(struct bch_fs *, struct stripe *, size_t);
[all …]
Dreplicas.h13 struct bch_fs *, struct printbuf *);
22 int bch2_replicas_entry_idx(struct bch_fs *,
29 bool bch2_replicas_marked_locked(struct bch_fs *,
31 bool bch2_replicas_marked(struct bch_fs *, struct bch_replicas_entry_v1 *);
32 int bch2_mark_replicas(struct bch_fs *,
46 bool bch2_have_enough_devs(struct bch_fs *, struct bch_devs_mask,
50 unsigned bch2_dev_has_data(struct bch_fs *, struct bch_dev *);
52 int bch2_replicas_gc_end(struct bch_fs *, int);
53 int bch2_replicas_gc_start(struct bch_fs *, unsigned);
54 int bch2_replicas_gc2(struct bch_fs *);
[all …]
Dbtree_journal_iter.h46 struct bkey_i *bch2_journal_keys_peek_upto(struct bch_fs *, enum btree_id,
48 struct bkey_i *bch2_journal_keys_peek_slot(struct bch_fs *, enum btree_id,
54 int bch2_journal_key_insert_take(struct bch_fs *, enum btree_id,
56 int bch2_journal_key_insert(struct bch_fs *, enum btree_id,
58 int bch2_journal_key_delete(struct bch_fs *, enum btree_id,
61 void bch2_journal_key_overwritten(struct bch_fs *, enum btree_id, unsigned, struct bpos);
73 void bch2_journal_keys_put(struct bch_fs *);
75 static inline void bch2_journal_keys_put_initial(struct bch_fs *c) in bch2_journal_keys_put_initial()
82 void bch2_journal_entries_free(struct bch_fs *);
84 int bch2_journal_keys_sort(struct bch_fs *);
[all …]
Dbtree_cache.h13 void bch2_recalc_btree_reserve(struct bch_fs *);
15 void bch2_btree_node_to_freelist(struct bch_fs *, struct btree *);
24 void bch2_node_pin(struct bch_fs *, struct btree *);
25 void bch2_btree_cache_unpin(struct bch_fs *);
33 struct btree *__bch2_btree_node_mem_alloc(struct bch_fs *);
48 void bch2_fs_btree_cache_exit(struct bch_fs *);
49 int bch2_fs_btree_cache_init(struct bch_fs *);
97 static inline size_t btree_max_u64s(const struct bch_fs *c) in btree_max_u64s()
102 static inline size_t btree_sectors(const struct bch_fs *c) in btree_sectors()
107 static inline unsigned btree_blocks(const struct bch_fs *c) in btree_blocks()
[all …]
Ddisk_groups.h59 const struct bch_devs_mask *bch2_target_to_mask(struct bch_fs *, unsigned);
61 static inline struct bch_devs_mask target_rw_devs(struct bch_fs *c, in target_rw_devs()
73 static inline bool bch2_target_accepts_data(struct bch_fs *c, in bch2_target_accepts_data()
81 bool bch2_dev_in_target(struct bch_fs *, unsigned, unsigned);
88 void bch2_disk_path_to_text(struct printbuf *, struct bch_fs *, unsigned);
91 void bch2_target_to_text(struct printbuf *out, struct bch_fs *, unsigned);
93 int bch2_opt_target_parse(struct bch_fs *, const char *, u64 *, struct printbuf *);
94 void bch2_opt_target_to_text(struct printbuf *, struct bch_fs *, struct bch_sb *, u64);
101 int bch2_sb_disk_groups_to_cpu(struct bch_fs *);
103 int __bch2_dev_group_set(struct bch_fs *, struct bch_dev *, const char *);
[all …]
Ddebug.h9 struct bch_fs;
11 void __bch2_btree_verify(struct bch_fs *, struct btree *);
12 void bch2_btree_node_ondisk_to_text(struct printbuf *, struct bch_fs *,
15 static inline void bch2_btree_verify(struct bch_fs *c, struct btree *b) in bch2_btree_verify()
22 void bch2_fs_debug_exit(struct bch_fs *);
23 void bch2_fs_debug_init(struct bch_fs *);
25 static inline void bch2_fs_debug_exit(struct bch_fs *c) {} in bch2_fs_debug_exit()
26 static inline void bch2_fs_debug_init(struct bch_fs *c) {} in bch2_fs_debug_init()
Dbtree_write_buffer.h8 static inline bool bch2_btree_write_buffer_should_flush(struct bch_fs *c) in bch2_btree_write_buffer_should_flush()
15 static inline bool bch2_btree_write_buffer_must_wait(struct bch_fs *c) in bch2_btree_write_buffer_must_wait()
24 bool bch2_btree_write_buffer_flush_going_ro(struct bch_fs *);
45 int bch2_accounting_key_to_wb_slowpath(struct bch_fs *,
48 static inline int bch2_accounting_key_to_wb(struct bch_fs *c, in bch2_accounting_key_to_wb()
68 int bch2_journal_key_to_wb_slowpath(struct bch_fs *,
72 static inline int __bch2_journal_key_to_wb(struct bch_fs *c, in __bch2_journal_key_to_wb()
88 static inline int bch2_journal_key_to_wb(struct bch_fs *c, in bch2_journal_key_to_wb()
99 void bch2_journal_keys_to_write_buffer_start(struct bch_fs *, struct journal_keys_to_wb *, u64);
100 int bch2_journal_keys_to_write_buffer_end(struct bch_fs *, struct journal_keys_to_wb *);
[all …]
Dalloc_background.h16 static inline bool bch2_dev_bucket_exists(struct bch_fs *c, struct bpos pos) in bch2_dev_bucket_exists()
248 int bch2_alloc_v1_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
249 int bch2_alloc_v2_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
250 int bch2_alloc_v3_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
251 int bch2_alloc_v4_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
253 void bch2_alloc_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
284 int bch2_bucket_gens_validate(struct bch_fs *, struct bkey_s_c,
286 void bch2_bucket_gens_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
293 int bch2_bucket_gens_init(struct bch_fs *);
302 int bch2_alloc_read(struct bch_fs *);
[all …]
Dfs-io.h63 static inline void __bch2_quota_reservation_put(struct bch_fs *c, in __bch2_quota_reservation_put()
75 static inline void bch2_quota_reservation_put(struct bch_fs *c, in bch2_quota_reservation_put()
86 static inline int bch2_quota_reservation_add(struct bch_fs *c, in bch2_quota_reservation_add()
111 static inline void __bch2_quota_reservation_put(struct bch_fs *c, in __bch2_quota_reservation_put()
115 static inline void bch2_quota_reservation_put(struct bch_fs *c, in bch2_quota_reservation_put()
119 static inline int bch2_quota_reservation_add(struct bch_fs *c, in bch2_quota_reservation_add()
130 void __bch2_i_sectors_acct(struct bch_fs *, struct bch_inode_info *,
133 static inline void bch2_i_sectors_acct(struct bch_fs *c, struct bch_inode_info *inode, in bch2_i_sectors_acct()
159 void bch2_inode_flush_nocow_writes_async(struct bch_fs *,
162 int __must_check bch2_write_inode_size(struct bch_fs *,
[all …]
Dbkey_methods.h7 struct bch_fs;
24 int (*key_validate)(struct bch_fs *c, struct bkey_s_c k,
26 void (*val_to_text)(struct printbuf *, struct bch_fs *,
29 bool (*key_normalize)(struct bch_fs *, struct bkey_s);
30 bool (*key_merge)(struct bch_fs *, struct bkey_s, struct bkey_s_c);
51 int bch2_bkey_val_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
52 int __bch2_bkey_validate(struct bch_fs *, struct bkey_s_c, enum btree_node_type,
54 int bch2_bkey_validate(struct bch_fs *, struct bkey_s_c, enum btree_node_type,
56 int bch2_bkey_in_btree_node(struct bch_fs *, struct btree *, struct bkey_s_c,
61 void bch2_val_to_text(struct printbuf *, struct bch_fs *,
[all …]
Dbtree_io.h12 struct bch_fs;
18 static inline void set_btree_node_dirty_acct(struct bch_fs *c, struct btree *b) in set_btree_node_dirty_acct()
24 static inline void clear_btree_node_dirty_acct(struct bch_fs *c, struct btree *b) in clear_btree_node_dirty_acct()
38 struct bch_fs *c;
70 bool bch2_compact_whiteouts(struct bch_fs *, struct btree *,
82 static inline bool bch2_maybe_compact_whiteouts(struct bch_fs *c, struct btree *b) in bch2_maybe_compact_whiteouts()
101 static inline int bset_encrypt(struct bch_fs *c, struct bset *i, unsigned offset) in bset_encrypt()
122 void bch2_btree_sort_into(struct bch_fs *, struct btree *, struct btree *);
129 int bch2_btree_node_read_done(struct bch_fs *, struct bch_dev *,
132 int bch2_btree_root_read(struct bch_fs *, enum btree_id,
[all …]
Dchecksum.h34 struct bch_csum bch2_checksum(struct bch_fs *, unsigned, struct nonce,
78 int bch2_encrypt(struct bch_fs *, unsigned, struct nonce,
81 struct bch_csum bch2_checksum_bio(struct bch_fs *, unsigned,
84 int bch2_rechecksum_bio(struct bch_fs *, struct bio *, struct bversion,
90 int __bch2_encrypt_bio(struct bch_fs *, unsigned,
93 static inline int bch2_encrypt_bio(struct bch_fs *c, unsigned type, in bch2_encrypt_bio()
103 int bch2_decrypt_sb_key(struct bch_fs *, struct bch_sb_field_crypt *,
106 int bch2_disable_encryption(struct bch_fs *);
107 int bch2_enable_encryption(struct bch_fs *, bool);
109 void bch2_fs_encryption_exit(struct bch_fs *);
[all …]
Dsb-members.h16 int bch2_sb_members_v2_init(struct bch_fs *c);
70 static inline struct bch_dev *__bch2_next_dev_idx(struct bch_fs *c, unsigned idx, in __bch2_next_dev_idx()
85 static inline struct bch_dev *__bch2_next_dev(struct bch_fs *c, struct bch_dev *ca, in __bch2_next_dev()
124 static inline struct bch_dev *bch2_get_next_dev(struct bch_fs *c, struct bch_dev *ca) in bch2_get_next_dev()
145 static inline struct bch_dev *bch2_get_next_online_dev(struct bch_fs *c, in bch2_get_next_online_dev()
175 static inline bool bch2_dev_exists(const struct bch_fs *c, unsigned dev) in bch2_dev_exists()
185 static inline struct bch_dev *bch2_dev_have_ref(const struct bch_fs *c, unsigned dev) in bch2_dev_have_ref()
192 static inline struct bch_dev *bch2_dev_locked(struct bch_fs *c, unsigned dev) in bch2_dev_locked()
201 static inline struct bch_dev *bch2_dev_rcu_noerror(struct bch_fs *c, unsigned dev) in bch2_dev_rcu_noerror()
208 void bch2_dev_missing(struct bch_fs *, unsigned);
[all …]
Drebalance.h7 int bch2_set_rebalance_needs_scan(struct bch_fs *, u64 inum);
8 int bch2_set_fs_needs_rebalance(struct bch_fs *);
10 static inline void rebalance_wakeup(struct bch_fs *c) in rebalance_wakeup()
21 void bch2_rebalance_status_to_text(struct printbuf *, struct bch_fs *);
23 void bch2_rebalance_stop(struct bch_fs *);
24 int bch2_rebalance_start(struct bch_fs *);
25 void bch2_fs_rebalance_init(struct bch_fs *);
Dsubvolume.h10 int bch2_check_subvols(struct bch_fs *);
11 int bch2_check_subvol_children(struct bch_fs *);
13 int bch2_subvolume_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
14 void bch2_subvolume_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
34 int bch2_subvol_is_ro(struct bch_fs *, u32);
81 int bch2_delete_dead_snapshots(struct bch_fs *);
82 void bch2_delete_dead_snapshots_async(struct bch_fs *);
87 int bch2_initialize_subvolumes(struct bch_fs *);
88 int bch2_fs_upgrade_for_subvolumes(struct bch_fs *);
90 int bch2_fs_subvolumes_init(struct bch_fs *);
Dsuper-io.h59 static inline __le64 bch2_sb_magic(struct bch_fs *c) in bch2_sb_magic()
67 static inline __u64 jset_magic(struct bch_fs *c) in jset_magic()
72 static inline __u64 bset_magic(struct bch_fs *c) in bset_magic()
77 int bch2_sb_to_fs(struct bch_fs *, struct bch_sb *);
78 int bch2_sb_from_fs(struct bch_fs *, struct bch_dev *);
85 int bch2_write_super(struct bch_fs *);
86 void __bch2_check_set_feature(struct bch_fs *, unsigned);
88 static inline void bch2_check_set_feature(struct bch_fs *c, unsigned feat) in bch2_check_set_feature()
94 bool bch2_check_version_downgrade(struct bch_fs *);
95 void bch2_sb_upgrade(struct bch_fs *, unsigned);
Dbtree_update_interior.h47 struct bch_fs *c;
172 void bch2_btree_node_rewrite_async(struct bch_fs *, struct btree *);
179 void bch2_btree_set_root_for_read(struct bch_fs *, struct btree *);
182 void bch2_btree_root_alloc_fake(struct bch_fs *, enum btree_id, unsigned);
184 static inline unsigned btree_update_reserve_required(struct bch_fs *c, in btree_update_reserve_required()
277 static inline struct btree_node_entry *want_new_bset(struct bch_fs *c, struct btree *b) in want_new_bset()
329 void bch2_btree_updates_to_text(struct printbuf *, struct bch_fs *);
331 bool bch2_btree_interior_updates_flush(struct bch_fs *);
333 void bch2_journal_entry_to_btree_root(struct bch_fs *, struct jset_entry *);
334 struct jset_entry *bch2_btree_roots_to_journal_entries(struct bch_fs *,
[all …]
Ddisk_accounting.h85 int bch2_accounting_validate(struct bch_fs *, struct bkey_s_c, enum bch_validate_flags);
87 void bch2_accounting_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c);
112 int bch2_accounting_mem_insert(struct bch_fs *, struct bkey_s_c_accounting, enum bch_accounting_mod…
113 void bch2_accounting_mem_gc(struct bch_fs *);
123 struct bch_fs *c = trans->c; in bch2_accounting_mem_mod_locked()
197 static inline void bch2_accounting_mem_read(struct bch_fs *c, struct bpos p, in bch2_accounting_mem_read()
207 int bch2_fs_replicas_usage_read(struct bch_fs *, darray_char *);
208 int bch2_fs_accounting_read(struct bch_fs *, darray_char *, unsigned);
209 void bch2_fs_accounting_to_text(struct printbuf *, struct bch_fs *);
211 int bch2_gc_accounting_start(struct bch_fs *);
[all …]
Dcompress.h50 int bch2_bio_uncompress_inplace(struct bch_fs *, struct bio *,
52 int bch2_bio_uncompress(struct bch_fs *, struct bio *, struct bio *,
54 unsigned bch2_bio_compress(struct bch_fs *, struct bio *, size_t *,
57 int bch2_check_set_has_compressed_data(struct bch_fs *, unsigned);
58 void bch2_fs_compress_exit(struct bch_fs *);
59 int bch2_fs_compress_init(struct bch_fs *);
63 int bch2_opt_compression_parse(struct bch_fs *, const char *, u64 *, struct printbuf *);
64 void bch2_opt_compression_to_text(struct printbuf *, struct bch_fs *, struct bch_sb *, u64);
Dsb-clean.h5 int bch2_sb_clean_validate_late(struct bch_fs *, struct bch_sb_field_clean *, int);
6 int bch2_verify_superblock_clean(struct bch_fs *, struct bch_sb_field_clean **,
8 struct bch_sb_field_clean *bch2_read_superblock_clean(struct bch_fs *);
9 void bch2_journal_super_entries_add_common(struct bch_fs *, struct jset_entry **, u64);
13 int bch2_fs_mark_dirty(struct bch_fs *);
14 void bch2_fs_mark_clean(struct bch_fs *);

123456