diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-12-10 23:29:06 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-01-01 11:47:43 -0500 |
commit | 311e446a414885aed71bc8106bdc4874774343c4 (patch) | |
tree | 1e317a603ba0dfe4a500d35c1e3ac053730e0298 /fs/bcachefs/btree_iter.c | |
parent | 1f75ba4e65c54ff0517d7cd073afceb0751d1a32 (diff) | |
download | linux-stable-311e446a414885aed71bc8106bdc4874774343c4.tar.gz linux-stable-311e446a414885aed71bc8106bdc4874774343c4.tar.bz2 linux-stable-311e446a414885aed71bc8106bdc4874774343c4.zip |
bcachefs: bch2_btree_path_to_text() -> btree_path_idx_t
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/btree_iter.c')
-rw-r--r-- | fs/bcachefs/btree_iter.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/bcachefs/btree_iter.c b/fs/bcachefs/btree_iter.c index 0f904a79d4e5..95c0a50ae03f 100644 --- a/fs/bcachefs/btree_iter.c +++ b/fs/bcachefs/btree_iter.c @@ -1413,11 +1413,12 @@ void bch2_dump_trans_updates(struct btree_trans *trans) printbuf_exit(&buf); } -noinline __cold -void bch2_btree_path_to_text(struct printbuf *out, struct btree_path *path) +static void bch2_btree_path_to_text(struct printbuf *out, struct btree_trans *trans, btree_path_idx_t path_idx) { + struct btree_path *path = trans->paths + path_idx; + prt_printf(out, "path: idx %2u ref %u:%u %c %c btree=%s l=%u pos ", - path->idx, path->ref, path->intent_ref, + path_idx, path->ref, path->intent_ref, path->preserve ? 'P' : ' ', path->should_be_locked ? 'S' : ' ', bch2_btree_id_str(path->btree_id), @@ -1436,13 +1437,12 @@ void __bch2_trans_paths_to_text(struct printbuf *out, struct btree_trans *trans, bool nosort) { struct trans_for_each_path_inorder_iter iter; - struct btree_path *path; if (!nosort) btree_trans_sort_paths(trans); - trans_for_each_path_inorder(trans, path, iter) - bch2_btree_path_to_text(out, path); + trans_for_each_path_idx_inorder(trans, iter) + bch2_btree_path_to_text(out, trans, iter.path_idx); } noinline __cold |