[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <9455cce5-af97-48cb-8042-24b714f29401@collabora.com>
Date: Sat, 19 Oct 2024 14:20:18 +0300
From: Cristian Ciocaltea <cristian.ciocaltea@...labora.com>
To: Stephen Boyd <sboyd@...nel.org>, Alim Akhtar <alim.akhtar@...sung.com>,
AngeloGioacchino Del Regno <angelogioacchino.delregno@...labora.com>,
Bjorn Helgaas <bhelgaas@...gle.com>, Jingoo Han <jingoohan1@...il.com>,
Krzysztof Kozlowski <krzk@...nel.org>, Krzysztof WilczyĆski
<kw@...ux.com>, Lorenzo Pieralisi <lpieralisi@...nel.org>,
Manivannan Sadhasivam <manivannan.sadhasivam@...aro.org>,
Matthias Brugger <matthias.bgg@...il.com>,
Michael Turquette <mturquette@...libre.com>, Rob Herring <robh@...nel.org>,
Russell King <linux@...linux.org.uk>
Cc: kernel@...labora.com, linux-clk@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org, linux-pci@...r.kernel.org,
linux-samsung-soc@...r.kernel.org
Subject: Re: [PATCH v3 1/4] clk: Provide devm_clk_bulk_get_all_enabled()
helper
On 10/19/24 8:56 AM, Stephen Boyd wrote:
> Quoting Cristian Ciocaltea (2024-10-17 16:17:29)
>> diff --git a/drivers/clk/clk-devres.c b/drivers/clk/clk-devres.c
>> index 82ae1f26e634572b943d18b8d86267f0a69911a6..0d0fe364b66a8590d5e7c63dc6c1e70c59d53e89 100644
>> --- a/drivers/clk/clk-devres.c
>> +++ b/drivers/clk/clk-devres.c
>> @@ -230,25 +239,27 @@ int __must_check devm_clk_bulk_get_all_enable(struct device *dev,
>> return -ENOMEM;
>>
>> ret = clk_bulk_get_all(dev, &devres->clks);
>> - if (ret > 0) {
>> - *clks = devres->clks;
>> - devres->num_clks = ret;
>> - } else {
>> - devres_free(devres);
>> - return ret;
>> - }
>> + if (ret <= 0)
>> + goto err_free_devres;
>
> Please don't use goto so that the diff is minimized.
Done in v4:
https://lore.kernel.org/all/20241019-clk_bulk_ena_fix-v4-0-57f108f64e70@collabora.com/
Regards,
Cristian
Powered by blists - more mailing lists