diff options
author | 2021-07-11 13:54:07 -0400 | |
---|---|---|
committer | 2023-10-22 17:09:08 -0400 | |
commit | 2680325b7803c336bb675addfe38c06c44e54273 (patch) | |
tree | 835aa6f52fc8b61f5451521fc1470bcb8d9797c6 /fs/bcachefs/super-io.c | |
parent | bcachefs: Really don't hold btree locks while btree IOs are in flight (diff) | |
download | linux-2680325b7803c336bb675addfe38c06c44e54273.tar.gz linux-2680325b7803c336bb675addfe38c06c44e54273.tar.bz2 linux-2680325b7803c336bb675addfe38c06c44e54273.zip |
bcachefs: Mask out unknown compat features when going read-write
Compat features should be cleared if the filesystem was touched by a
version that doesn't support them.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to 'fs/bcachefs/super-io.c')
-rw-r--r-- | fs/bcachefs/super-io.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/bcachefs/super-io.c b/fs/bcachefs/super-io.c index 403e77e2c515..be080c407286 100644 --- a/fs/bcachefs/super-io.c +++ b/fs/bcachefs/super-io.c @@ -985,6 +985,7 @@ int bch2_fs_mark_dirty(struct bch_fs *c) mutex_lock(&c->sb_lock); SET_BCH_SB_CLEAN(c->disk_sb.sb, false); c->disk_sb.sb->features[0] |= cpu_to_le64(BCH_SB_FEATURES_ALWAYS); + c->disk_sb.sb->compat[0] &= cpu_to_le64((1ULL << BCH_COMPAT_NR) - 1); ret = bch2_write_super(c); mutex_unlock(&c->sb_lock); |