+enum lfsck_layout_inconsistency_type {
+ LLIT_NONE = 0,
+ LLIT_DANGLING = 1,
+ LLIT_UNMATCHED_PAIR = 2,
+ LLIT_MULTIPLE_REFERENCED = 3,
+ LLIT_ORPHAN = 4,
+ LLIT_INCONSISTENT_OWNER = 5,
+ LLIT_OTHERS = 6,
+ LLIT_MAX = LLIT_OTHERS
+};
+
+struct lfsck_layout {
+ /* Magic number to detect that this struct contains valid data. */
+ __u32 ll_magic;
+
+ /* See 'enum lfsck_status'. */
+ __u32 ll_status;
+
+ /* See 'enum lfsck_flags'. */
+ __u32 ll_flags;
+
+ /* How many completed LFSCK runs on the device. */
+ __u32 ll_success_count;
+
+ /* How long the LFSCK phase1 has run in seconds. */
+ __u32 ll_run_time_phase1;
+
+ /* How long the LFSCK phase2 has run in seconds. */
+ __u32 ll_run_time_phase2;
+
+ /* Time for the last LFSCK completed in seconds since epoch. */
+ __u64 ll_time_last_complete;
+
+ /* Time for the latest LFSCK ran in seconds since epoch. */
+ __u64 ll_time_latest_start;
+
+ /* Time for the last LFSCK checkpoint in seconds since epoch. */
+ __u64 ll_time_last_checkpoint;
+
+ /* Position for the latest LFSCK started from. */
+ __u64 ll_pos_latest_start;
+
+ /* Position for the last LFSCK checkpoint. */
+ __u64 ll_pos_last_checkpoint;
+
+ /* Position for the first should be updated object. */
+ __u64 ll_pos_first_inconsistent;
+
+ /* How many objects have been checked. */
+ __u64 ll_objs_checked_phase1;
+
+ /* How many objects failed to be processed. */
+ __u64 ll_objs_failed_phase1;
+
+ /* How many objects have been double scanned. */
+ __u64 ll_objs_checked_phase2;
+
+ /* How many objects failed to be processed during double scan. */
+ __u64 ll_objs_failed_phase2;
+
+ /* kinds of inconsistency have been repaired.
+ * ll_objs_repaired[type - 1] is the count for the given @type. */
+ __u64 ll_objs_repaired[LLIT_MAX];
+
+ /* How many objects have been skipped because of related
+ * MDT(s)/OST(s) do not participate in the LFSCK */
+ __u64 ll_objs_skipped;
+
+ /* For further using. 256-bytes aligned now. */
+ __u64 ll_reserved[12];
+};
+