summaryrefslogtreecommitdiff
path: root/libbcachefs/super_types.h
diff options
context:
space:
mode:
Diffstat (limited to 'libbcachefs/super_types.h')
-rw-r--r--libbcachefs/super_types.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/libbcachefs/super_types.h b/libbcachefs/super_types.h
index 756dfeba..35c8bebf 100644
--- a/libbcachefs/super_types.h
+++ b/libbcachefs/super_types.h
@@ -13,4 +13,33 @@ struct bch_devs_mask {
unsigned long d[BITS_TO_LONGS(BCH_SB_MEMBERS_MAX)];
};
+struct bch_devs_list {
+ u8 nr;
+ u8 devs[BCH_REPLICAS_MAX];
+};
+
+struct bch_member_cpu {
+ u64 nbuckets; /* device size */
+ u16 first_bucket; /* index of first bucket used */
+ u16 bucket_size; /* sectors */
+ u8 state;
+ u8 tier;
+ u8 replacement;
+ u8 discard;
+ u8 data_allowed;
+ u8 valid;
+};
+
+struct bch_replicas_cpu_entry {
+ u8 data_type;
+ u8 devs[BCH_SB_MEMBERS_MAX / 8];
+};
+
+struct bch_replicas_cpu {
+ struct rcu_head rcu;
+ unsigned nr;
+ unsigned entry_size;
+ struct bch_replicas_cpu_entry entries[];
+};
+
#endif /* _BCACHEFS_SUPER_TYPES_H */