diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2019-11-06 15:32:11 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:08:31 -0400 |
commit | e2ee3eaab72a059b29f079290b5773509df9524f (patch) | |
tree | cd66c550f6cc68a395f68150c9941dab2541d095 /fs/bcachefs/opts.h | |
parent | ef496cd268f45351820c3d268d01bd46c8b80b04 (diff) | |
download | linux-stable-e2ee3eaab72a059b29f079290b5773509df9524f.tar.gz linux-stable-e2ee3eaab72a059b29f079290b5773509df9524f.tar.bz2 linux-stable-e2ee3eaab72a059b29f079290b5773509df9524f.zip |
bcachefs: Add an option for fsck error ratelimiting
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/opts.h')
-rw-r--r-- | fs/bcachefs/opts.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/fs/bcachefs/opts.h b/fs/bcachefs/opts.h index a6f1d3ec7b90..2bd8bce43269 100644 --- a/fs/bcachefs/opts.h +++ b/fs/bcachefs/opts.h @@ -68,6 +68,12 @@ enum opt_type { * - helptext */ +#ifdef __KERNEL__ +#define RATELIMIT_ERRORS true +#else +#define RATELIMIT_ERRORS false +#endif + #define BCH_OPTS() \ x(block_size, u16, \ OPT_FORMAT, \ @@ -227,6 +233,11 @@ enum opt_type { OPT_BOOL(), \ NO_SB_OPT, false, \ NULL, "Fix errors during fsck without asking") \ + x(ratelimit_errors, u8, \ + OPT_MOUNT, \ + OPT_BOOL(), \ + NO_SB_OPT, RATELIMIT_ERRORS, \ + NULL, "Ratelimit error messages during fsck") \ x(nochanges, u8, \ OPT_MOUNT, \ OPT_BOOL(), \ |