Re: [PATCH] soc: qcom: wcnss_ctrl: fix firmware leak on req allocation failure
From: Dmitry Baryshkov
Date: Fri Apr 17 2026 - 18:57:11 EST
On Fri, Apr 17, 2026 at 09:17:52PM +0800, Felix Gu wrote:
> In wcnss_download_nv(), if kzalloc_flex() fails, the current code
> returns -ENOMEM directly and leaves the firmware reference unreleased.
>
> Fixes: 908061f0ad30 ("soc: qcom: wcnss: simplify allocation of req")
> Signed-off-by: Felix Gu <ustc.gu@xxxxxxxxx>
> ---
> drivers/soc/qcom/wcnss_ctrl.c | 11 +++++++----
> 1 file changed, 7 insertions(+), 4 deletions(-)
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@xxxxxxxxxxxxxxxx>
>
--
With best wishes
Dmitry