summaryrefslogtreecommitdiff
path: root/fs/bcachefs/opts.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@gmail.com>2018-07-24 14:55:05 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-22 17:08:08 -0400
commita50ed7c8e83e52dbfd54a47b5e123f85f5cd91f1 (patch)
tree93b9ef7db941583fe8a26920129c8586cdb11853 /fs/bcachefs/opts.h
parenta9bec5208b4379c87fa8361f813cb71b5581540e (diff)
bcachefs: BCH_SB_RESERVE_BYTES
Add an option, gc_reserve_bytes, to set the copygc reserve as a size instead of a percent 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, 4 insertions, 1 deletions
diff --git a/fs/bcachefs/opts.h b/fs/bcachefs/opts.h
index 3b5eddbf56bf..01f1cb53eb5f 100644
--- a/fs/bcachefs/opts.h
+++ b/fs/bcachefs/opts.h
@@ -114,9 +114,12 @@ enum opt_type {
BCH_OPT(inodes_32bit, u8, OPT_RUNTIME, \
OPT_BOOL(), \
BCH_SB_INODE_32BIT, false) \
- BCH_OPT(gc_reserve_percent, u8, OPT_MOUNT, \
+ BCH_OPT(gc_reserve_percent, u8, OPT_RUNTIME, \
OPT_UINT(5, 21), \
BCH_SB_GC_RESERVE, 8) \
+ BCH_OPT(gc_reserve_bytes, u64, OPT_RUNTIME, \
+ OPT_UINT(0, U64_MAX), \
+ BCH_SB_GC_RESERVE_BYTES, 0) \
BCH_OPT(root_reserve_percent, u8, OPT_MOUNT, \
OPT_UINT(0, 100), \
BCH_SB_ROOT_RESERVE, 0) \