summaryrefslogtreecommitdiff
path: root/libbcachefs/recovery_passes.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2025-07-23 22:55:48 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2025-07-23 22:55:48 -0400
commitfa7be73f307a24ebf3a958ba389d33f43321293f (patch)
tree3493ddfb9a859d159e8641f32bd35055a55aeb23 /libbcachefs/recovery_passes.h
parent5023292623e8f1dedc138a20daabbcc4772a0d86 (diff)
Update bcachefs sources to d90e3ac64900 bcachefs: live_child() no longer uses recursiondebug
Diffstat (limited to 'libbcachefs/recovery_passes.h')
-rw-r--r--libbcachefs/recovery_passes.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/libbcachefs/recovery_passes.h b/libbcachefs/recovery_passes.h
index 4f2c2f81..95e3612b 100644
--- a/libbcachefs/recovery_passes.h
+++ b/libbcachefs/recovery_passes.h
@@ -26,6 +26,12 @@ static inline bool go_rw_in_recovery(struct bch_fs *c)
(c->opts.fsck && !(c->sb.features & BIT_ULL(BCH_FEATURE_no_alloc_info))));
}
+static inline bool recovery_pass_will_run(struct bch_fs *c, enum bch_recovery_pass pass)
+{
+ return unlikely(test_bit(BCH_FS_in_recovery, &c->flags) &&
+ c->recovery.passes_to_run & BIT_ULL(pass));
+}
+
int bch2_run_print_explicit_recovery_pass(struct bch_fs *, enum bch_recovery_pass);
int __bch2_run_explicit_recovery_pass(struct bch_fs *, struct printbuf *,