lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <b3ef3855-f95f-43ad-9a2a-3803c1f00046@kernel.org>
Date: Fri, 22 Nov 2024 08:01:39 +0100
From: Krzysztof Kozlowski <krzk@...nel.org>
To: Jiasheng Jiang <jiashengjiangcool@...il.com>,
 sylvester.nawrocki@...il.com, mchehab@...nel.org, dron0gus@...il.com,
 tomasz.figa@...il.com, alim.akhtar@...sung.com, kyungmin.park@...sung.com,
 laurent.pinchart@...asonboard.com
Cc: linux-media@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
 linux-samsung-soc@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] media: mipi-csis: Add check for clk_enable()

On 21/11/2024 22:05, Jiasheng Jiang wrote:
> Add check for the return value of clk_enable() to gurantee the success.
> 
> Fixes: b5f1220d587d ("[media] v4l: Add v4l2 subdev driver for S5P/EXYNOS4 MIPI-CSI receivers")
> Signed-off-by: Jiasheng Jiang <jiashengjiangcool@...il.com>
> ---
>  drivers/media/platform/samsung/exynos4-is/mipi-csis.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/media/platform/samsung/exynos4-is/mipi-csis.c b/drivers/media/platform/samsung/exynos4-is/mipi-csis.c
> index 63f3eecdd7e6..d1c938065475 100644
> --- a/drivers/media/platform/samsung/exynos4-is/mipi-csis.c
> +++ b/drivers/media/platform/samsung/exynos4-is/mipi-csis.c
> @@ -940,7 +940,9 @@ static int s5pcsis_pm_resume(struct device *dev, bool runtime)
>  					       state->supplies);
>  			goto unlock;
>  		}
> -		clk_enable(state->clock[CSIS_CLK_GATE]);
> +		ret = clk_enable(state->clock[CSIS_CLK_GATE]);
> +		if (ret)
> +			goto unlock;

You should unwind the work done, so power off the phy and disble regulators.

Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ