diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2021-07-26 22:52:41 +0300 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-23 00:09:09 +0300 |
commit | a32b9573c742c9a9289aa26e0a28d0f9a9c439a4 (patch) | |
tree | caf521241069c11f2f49c612e7dd64f78143a557 /fs/bcachefs/opts.h | |
parent | 2b4e4b8cfa3857cd44506b2e57fd587e7494d777 (diff) | |
download | linux-a32b9573c742c9a9289aa26e0a28d0f9a9c439a4.tar.xz |
bcachefs: Add an option for btree node mem ptr optimization
bch2_btree_node_ptr_v2 has a field for stashing a pointer to the in
memory btree node; this is safe because we clear this field when reading
in nodes from disk and we never free in memory btree nodes - but, we
have bug reports that indicate something might be faulty with this
optimization, so let's add an option for it.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to 'fs/bcachefs/opts.h')
-rw-r--r-- | fs/bcachefs/opts.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/bcachefs/opts.h b/fs/bcachefs/opts.h index 2cba0e137b58..0799c9d2bee0 100644 --- a/fs/bcachefs/opts.h +++ b/fs/bcachefs/opts.h @@ -178,6 +178,11 @@ enum opt_type { OPT_BOOL(), \ BCH_SB_INODES_USE_KEY_CACHE, true, \ NULL, "Use the btree key cache for the inodes btree") \ + x(btree_node_mem_ptr_optimization, u8, \ + OPT_MOUNT|OPT_RUNTIME, \ + OPT_BOOL(), \ + NO_SB_OPT, true, \ + NULL, "Stash pointer to in memory btree node in btree ptr")\ x(gc_reserve_percent, u8, \ OPT_FORMAT|OPT_MOUNT|OPT_RUNTIME, \ OPT_UINT(5, 21), \ |