bcachefs: fix mempool double initialization
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
8812600c29
commit
e647369168
@ -596,11 +596,13 @@ have_compressed:
|
||||
goto out;
|
||||
}
|
||||
|
||||
ret = mempool_init_kmalloc_pool(
|
||||
&c->decompress_workspace,
|
||||
1, decompress_workspace_size);
|
||||
if (ret)
|
||||
goto out;
|
||||
if (!mempool_initialized(&c->decompress_workspace)) {
|
||||
ret = mempool_init_kmalloc_pool(
|
||||
&c->decompress_workspace,
|
||||
1, decompress_workspace_size);
|
||||
if (ret)
|
||||
goto out;
|
||||
}
|
||||
out:
|
||||
pr_verbose_init(c->opts, "ret %i", ret);
|
||||
return ret;
|
||||
|
Loading…
Reference in New Issue
Block a user