diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-08-01 20:06:45 -0400 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:10:09 -0400 |
commit | bf5a261c7af80a2ac10bcc3ce0382cb238eccb8b (patch) | |
tree | ba891c5c8486cc26935c90b4c899baf1ae86af9d /fs/bcachefs/opts.c | |
parent | 7904c82ceae963b0f89e96a49dc714adffe3adc6 (diff) | |
download | lwn-bf5a261c7af80a2ac10bcc3ce0382cb238eccb8b.tar.gz lwn-bf5a261c7af80a2ac10bcc3ce0382cb238eccb8b.zip |
bcachefs: Assorted fixes for clang
clang had a few more warnings about enum conversion, and also didn't
like the opts.c initializer.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/opts.c')
-rw-r--r-- | fs/bcachefs/opts.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/bcachefs/opts.c b/fs/bcachefs/opts.c index 3a6fd1d96ed2..4d0daeba6f59 100644 --- a/fs/bcachefs/opts.c +++ b/fs/bcachefs/opts.c @@ -121,10 +121,10 @@ static void bch2_opt_fix_errors_to_text(struct printbuf *out, prt_str(out, bch2_fsck_fix_opts[v]); } -static const struct bch_opt_fn bch2_opt_fix_errors = { - .parse = bch2_opt_fix_errors_parse, - .to_text = bch2_opt_fix_errors_to_text, -}; +#define bch2_opt_fix_errors (struct bch_opt_fn) { \ + .parse = bch2_opt_fix_errors_parse, \ + .to_text = bch2_opt_fix_errors_to_text, \ +} const char * const bch2_d_types[BCH_DT_MAX] = { [DT_UNKNOWN] = "unknown", |