+
+ /* Ignore UUID mismatches */
+ OPEN_CTREE_IGNORE_FSID_MISMATCH = (1U << 10),
+
+ /*
+ * Allow open_ctree_fs_info() to return an incomplete fs_info with
+ * system chunks from super block only.
+ * It's useful when chunks are corrupted.
+ * Makes no sense for open_ctree variants returning btrfs_root.
+ */
+ OPEN_CTREE_IGNORE_CHUNK_TREE_ERROR = (1U << 11),
+
+ /*
+ * Allow to open fs with temporary superblock (BTRFS_MAGIC_PARTIAL),
+ * such fs contains very basic tree layout, just able to be opened.
+ * Such temporary super is used for mkfs or convert.
+ */
+ OPEN_CTREE_TEMPORARY_SUPER = (1U << 12),
+
+ /*
+ * Invalidate the free space tree (i.e., clear the FREE_SPACE_TREE_VALID
+ * compat_ro bit).
+ */
+ OPEN_CTREE_INVALIDATE_FST = (1U << 13),
+};
+
+/*
+ * Modes of superblock access
+ */
+enum btrfs_read_sb_flags {
+ SBREAD_DEFAULT = 0,
+ /* Reading superblock during recovery */
+ SBREAD_RECOVER = (1 << 0),
+
+ /*
+ * Read superblock with the fake signature, cannot be used with
+ * SBREAD_RECOVER
+ */
+ SBREAD_TEMPORARY = (1 << 1),