mirror of
https://github.com/torvalds/linux.git
synced 2024-11-29 23:51:37 +00:00
bcachefs: unregister_shrinker() now safe on not-registered shrinker
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
0ce4e0e759
commit
b3591acc3b
@ -398,7 +398,6 @@ void bch2_fs_btree_cache_exit(struct bch_fs *c)
|
||||
struct btree *b;
|
||||
unsigned i, flags;
|
||||
|
||||
if (bc->shrink.list.next)
|
||||
unregister_shrinker(&bc->shrink);
|
||||
|
||||
/* vfree() can allocate memory: */
|
||||
|
@ -955,7 +955,6 @@ void bch2_fs_btree_key_cache_exit(struct btree_key_cache *bc)
|
||||
int cpu;
|
||||
#endif
|
||||
|
||||
if (bc->shrink.list.next)
|
||||
unregister_shrinker(&bc->shrink);
|
||||
|
||||
mutex_lock(&bc->lock);
|
||||
|
Loading…
Reference in New Issue
Block a user