diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-11-26 23:05:02 +0100 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-01-01 17:47:38 +0100 |
commit | 3c471b65889aa22d6ba4f8e3d2e5006bb70fdb58 (patch) | |
tree | 70d3742bc3bfee17cb313f6d56fd9682e27070f7 /fs/bcachefs/super.h | |
parent | bcachefs: Kill journal_seq/gc args to bch2_dev_usage_update_m() (diff) | |
download | linux-3c471b65889aa22d6ba4f8e3d2e5006bb70fdb58.tar.xz linux-3c471b65889aa22d6ba4f8e3d2e5006bb70fdb58.zip |
bcachefs: convert bch_fs_flags to x-macro
Now we can print out filesystem flags in sysfs, useful for debugging
various "what's my filesystem doing" issues.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/super.h')
-rw-r--r-- | fs/bcachefs/super.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/bcachefs/super.h b/fs/bcachefs/super.h index bf762df18012..dada09331d2e 100644 --- a/fs/bcachefs/super.h +++ b/fs/bcachefs/super.h @@ -8,6 +8,8 @@ #include <linux/math64.h> +extern const char * const bch2_fs_flag_strs[]; + struct bch_fs *bch2_dev_to_fs(dev_t); struct bch_fs *bch2_uuid_to_fs(__uuid_t); @@ -37,8 +39,8 @@ int bch2_fs_read_write_early(struct bch_fs *); */ static inline void bch2_fs_lazy_rw(struct bch_fs *c) { - if (!test_bit(BCH_FS_RW, &c->flags) && - !test_bit(BCH_FS_WAS_RW, &c->flags)) + if (!test_bit(BCH_FS_rw, &c->flags) && + !test_bit(BCH_FS_was_rw, &c->flags)) bch2_fs_read_write_early(c); } |