Re: [PATCH v2 1/2] spi: meson-spicc: fix memory leak in meson_spicc_probe

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On 13/06/2021 07:29, zpershuai wrote:
> when meson_spicc_clk_init returns failed, it should goto the
> out_clk label.
> 
> Signed-off-by: zpershuai <zpershuai@xxxxxxxxx>
> ---
>  drivers/spi/spi-meson-spicc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/spi/spi-meson-spicc.c b/drivers/spi/spi-meson-spicc.c
> index ecba6b4..d675334 100644
> --- a/drivers/spi/spi-meson-spicc.c
> +++ b/drivers/spi/spi-meson-spicc.c
> @@ -752,7 +752,7 @@ static int meson_spicc_probe(struct platform_device *pdev)
>  	ret = meson_spicc_clk_init(spicc);
>  	if (ret) {
>  		dev_err(&pdev->dev, "clock registration failed\n");
> -		goto out_master;
> +		goto out_clk;
>  	}
>  
>  	ret = devm_spi_register_master(&pdev->dev, master);
> 

Reviewed-by: Neil Armstrong <narmstrong@xxxxxxxxxxxx>



[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux