mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-06 03:45:24 -04:00
UPSTREAM: erofs: fix an error code in z_erofs_init_zip_subsystem()
Moto-CRs-Fixed:(CR)
Return -ENOMEM if alloc_workqueue() fails. Don't return success.
Fixes: d8a650adf429 ("erofs: add per-cpu threads for decompression as an option")
Bug: 271636421
Tests: launch_cvd
Change-Id: I49dcf8094655db47ac71ae8967b5402373fc7adc
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>
Link: https://lore.kernel.org/r/Y+4d0FRsUq8jPoOu@kili
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
(cherry picked from commit 8d1b80a79452630f157bf634ae9cfcd9f4eed161)
Signed-off-by: Sandeep Dhavale <dhavale@google.com>
(cherry picked from commit 5004cc655730355d681b333ff5eafd62a4ee02f2)
Reviewed-on: https://gerrit.mot.com/2579833
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
parent
34486c7365
commit
45482ab6d3
1 changed files with 3 additions and 1 deletions
|
|
@ -260,8 +260,10 @@ int __init z_erofs_init_zip_subsystem(void)
|
|||
|
||||
z_erofs_workqueue = alloc_workqueue("erofs_worker",
|
||||
WQ_UNBOUND | WQ_HIGHPRI, num_possible_cpus());
|
||||
if (!z_erofs_workqueue)
|
||||
if (!z_erofs_workqueue) {
|
||||
err = -ENOMEM;
|
||||
goto out_error_workqueue_init;
|
||||
}
|
||||
|
||||
err = erofs_init_percpu_workers();
|
||||
if (err)
|
||||
|
|
|
|||
Loading…
Reference in a new issue