]> git.sesse.net Git - bcachefs-tools-debian/blobdiff - libbcachefs/replicas_types.h
Move c_src dirs back to toplevel
[bcachefs-tools-debian] / libbcachefs / replicas_types.h
index 3061840b6a02bfb241b0bd01fcb764aa6c42a6e6..ac90d142c4e87dde7d5df8753937e6ae0f0cb440 100644 (file)
@@ -1,11 +1,27 @@
+/* SPDX-License-Identifier: GPL-2.0 */
 #ifndef _BCACHEFS_REPLICAS_TYPES_H
 #define _BCACHEFS_REPLICAS_TYPES_H
 
 struct bch_replicas_cpu {
-       struct rcu_head         rcu;
        unsigned                nr;
        unsigned                entry_size;
-       struct bch_replicas_entry entries[];
+       struct bch_replicas_entry_v1 *entries;
+};
+
+struct replicas_delta {
+       s64                     delta;
+       struct bch_replicas_entry_v1 r;
+} __packed;
+
+struct replicas_delta_list {
+       unsigned                size;
+       unsigned                used;
+
+       struct                  {} memset_start;
+       u64                     nr_inodes;
+       u64                     persistent_reserved[BCH_REPLICAS_MAX];
+       struct                  {} memset_end;
+       struct replicas_delta   d[];
 };
 
 #endif /* _BCACHEFS_REPLICAS_TYPES_H */