Re: [PATCH v3 1/4] clk: Provide devm_clk_bulk_get_all_enabled() helper

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

 



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@xxxxxxxxxxxxx/

Regards,
Cristian




[Index of Archives]     [Linux SoC Development]     [Linux Rockchip Development]     [Linux for Synopsys ARC Processors]    
  • [Linux on Unisoc (RDA Micro) SoCs]     [Linux Actions SoC]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Linux SCSI]     [Yosemite News]

  •   Powered by Linux