summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2025-08-08 19:34:08 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2025-08-08 19:35:16 -0400
commit530e8ade4e6af7d152f4f79bf9f2b9dec6441f2b (patch)
tree084270bb4753d359209edc71b56866709fbb0a27
parent28db8e8e792288f91fd3165d887fd27208918dc0 (diff)
device_scan now uses no_version_check
Fix a compatibility issue - old tools can now mount newer filesystems with incompatible features, even if they can't do anything else with them. cmd_show_super now uses no_version_check as well. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
-rw-r--r--c_src/cmd_super.c1
-rw-r--r--src/device_scan.rs1
2 files changed, 2 insertions, 0 deletions
diff --git a/c_src/cmd_super.c b/c_src/cmd_super.c
index 4eacabc0..7e270769 100644
--- a/c_src/cmd_super.c
+++ b/c_src/cmd_super.c
@@ -159,6 +159,7 @@ int cmd_show_super(int argc, char *argv[])
opt_set(opts, noexcl, true);
opt_set(opts, nochanges, true);
+ opt_set(opts, no_version_check, true);
struct bch_sb_handle sb;
int ret = bch2_read_super(dev, &opts, &sb);
diff --git a/src/device_scan.rs b/src/device_scan.rs
index a6b62290..0361739f 100644
--- a/src/device_scan.rs
+++ b/src/device_scan.rs
@@ -19,6 +19,7 @@ use log::debug;
fn read_super_silent(path: impl AsRef<Path>, mut opts: bch_opts) -> anyhow::Result<bch_sb_handle> {
opt_set!(opts, noexcl, 1);
+ opt_set!(opts, no_version_check, 1);
bch_bindgen::sb_io::read_super_silent(path.as_ref(), opts)
}