[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <18289705-1025-2851-d24c-91a8da4910e1@huawei.com>
Date: Tue, 3 Nov 2020 16:18:01 +0800
From: Qinglang Miao <miaoqinglang@...wei.com>
To: Mark Brown <broonie@...nel.org>,
Matthias Brugger <matthias.bgg@...il.com>
CC: <linux-spi@...r.kernel.org>,
<linux-arm-kernel@...ts.infradead.org>,
<linux-mediatek@...ts.infradead.org>,
<linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] spi: mt7621: fix missing clk_disable_unprepare() on
error in mt7621_spi_probe
在 2020/11/3 15:49, Qinglang Miao 写道:
> Fix the missing clk_disable_unprepare() before return
> from mt7621_spi_probe in the error handling case.
>
> Fixes: cbd66c626e16 ("spi: mt7621: Move SPI driver out of staging")
> Signed-off-by: Qinglang Miao <miaoqinglang@...wei.com>
> ---
> drivers/spi/spi-mt7621.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/spi/spi-mt7621.c b/drivers/spi/spi-mt7621.c
> index 2c3b7a2a1..2cdae7994 100644
> --- a/drivers/spi/spi-mt7621.c
> +++ b/drivers/spi/spi-mt7621.c
> @@ -353,6 +353,7 @@ static int mt7621_spi_probe(struct platform_device *pdev)
> master = spi_alloc_master(&pdev->dev, sizeof(*rs));
> if (!master) {
> dev_info(&pdev->dev, "master allocation failed\n");
> + clk_disable_unprepare(clk);
> return -ENOMEM;
> }
>
> @@ -377,6 +378,7 @@ static int mt7621_spi_probe(struct platform_device *pdev)
> ret = device_reset(&pdev->dev);
> if (ret) {
> dev_err(&pdev->dev, "SPI reset failed!\n");
> + clk_disable_unprepare(clk);
> return ret;
> }
>
>
Hi Mark and Matthias,
I made a careless mistake for adding v2 as subject-prefix, this patch is
the base version actually.
Sorry about that.
Thanks.
Powered by blists - more mailing lists