@@ -294,6 +294,16 @@ static inline unsigned long btrfs_chunk_item_size(int num_stripes)
#define BTRFS_FSID_SIZE 16
#define BTRFS_HEADER_FLAG_WRITTEN (1ULL << 0)
#define BTRFS_HEADER_FLAG_RELOC (1ULL << 1)
+
+/*
+ * File system states
+ */
+
+/* Unmount cleanly */
+#define BTRFS_SUPER_FLAG_VALID (1ULL << 2)
+/* Errors detected */
+#define BTRFS_SUPER_FLAG_ERROR (1ULL << 3)
+
#define BTRFS_SUPER_FLAG_SEEDING (1ULL << 32)
#define BTRFS_SUPER_FLAG_METADUMP (1ULL << 33)
@@ -1050,6 +1060,9 @@ struct btrfs_fs_info {
unsigned metadata_ratio;
void *bdev_holder;
+
+ /* filesystem state */
+ unsigned short fs_state;
};
/*