bcachefs: Don't drop journal pins in exit path
authorKent Overstreet <kent.overstreet@linux.dev>
Fri, 1 Dec 2023 04:32:20 +0000 (23:32 -0500)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 3 Dec 2023 17:44:18 +0000 (12:44 -0500)
commit0117591e69d1edff46bc87061e533a1e25a8c500
treec5bff44bcfa353b11f4d0025c9c1b3ce405daee7
parent33cc938e65a98f1d29d0a18403dbbee050dcad9a
bcachefs: Don't drop journal pins in exit path

There's no need to drop journal pins in our exit paths - the code was
trying to have everything cleaned up on any shutdown, but better to just
tweak the assertions a bit.

This fixes a bug where calling into journal reclaim in the exit path
would cass a null ptr deref.

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