bcachefs: Refactor bch2_btree_iter()
authorKent Overstreet <kent.overstreet@gmail.com>
Sun, 9 Jan 2022 06:07:29 +0000 (01:07 -0500)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:09:22 +0000 (17:09 -0400)
commita1e82d35f89793f6347945ab48d799ce1802df87
treeef0b0419dcfebbabb60e889cb025a50360ad45c9
parentbc82d08bae53b48ca64e204392f6d336fc9509a9
bcachefs: Refactor bch2_btree_iter()

This splits bch2_btree_iter() up into two functions: an inner function
that handles BTREE_ITER_WITH_JOURNAL, BTREE_ITER_WITH_UPDATES, and
iterating acrcoss leaf nodes, and an outer one that implements
BTREE_ITER_FILTER_SNAPHSOTS.

This is prep work for remember a btree_path at our update position in
BTREE_ITER_FILTER_SNAPSHOTS mode.

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/btree_iter.c
fs/bcachefs/btree_iter.h