summaryrefslogtreecommitdiff
path: root/fs/bcachefs/opts.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2025-05-05 20:35:36 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2025-05-21 20:14:48 -0400
commit96fc7d8adb7881f7ffffcd6ab2be3b43fc5a5978 (patch)
tree2262a91f39c9c3e9c74a9e63b59c192554ec026e /fs/bcachefs/opts.h
parent502222041c810b5d5ba5d45512e0a131c7f07d0a (diff)
bcachefs: opts.rebalance_on_ac_only
Add an option for setting rebalance to only run when connected to mains power. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/opts.h')
-rw-r--r--fs/bcachefs/opts.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/bcachefs/opts.h b/fs/bcachefs/opts.h
index b8cd0b04e62a..f4c014ad43c1 100644
--- a/fs/bcachefs/opts.h
+++ b/fs/bcachefs/opts.h
@@ -490,6 +490,11 @@ enum fsck_err_opts {
BCH2_NO_SB_OPT, true, \
NULL, "Enable rebalance: disable for debugging, or to\n"\
"quiet the system when doing performance testing\n")\
+ x(rebalance_on_ac_only, u8, \
+ OPT_FS|OPT_MOUNT|OPT_RUNTIME, \
+ OPT_BOOL(), \
+ BCH_SB_REBALANCE_AC_ONLY, false, \
+ NULL, "Enable rebalance while on mains power only\n") \
x(no_data_io, u8, \
OPT_MOUNT, \
OPT_BOOL(), \