[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75Vc3dazcM1MLzjzPUmgMGNACUsOZ8aK4uauAJk0hzj9q-w@mail.gmail.com>
Date: Sat, 20 Aug 2022 01:14:57 +0300
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Bartosz Golaszewski <brgl@...ev.pl>
Cc: Robert Jarzmik <robert.jarzmik@...e.fr>,
Linus Walleij <linus.walleij@...aro.org>,
"open list:GPIO SUBSYSTEM" <linux-gpio@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Hulk Robot <hulkci@...wei.com>, Yuan Can <yuancan@...wei.com>
Subject: Re: [PATCH] gpio: pxa: use devres for the clock struct
On Mon, Aug 15, 2022 at 12:26 PM Bartosz Golaszewski <brgl@...ev.pl> wrote:
>
> The clock is never released after probe(). Use devres to not leak
> resources.
...
> - clk = clk_get(&pdev->dev, NULL);
> + clk = devm_clk_get_enabled(&pdev->dev, NULL);
> if (IS_ERR(clk)) {
> dev_err(&pdev->dev, "Error %ld to get gpio clock\n",
> PTR_ERR(clk));
> return PTR_ERR(clk);
Shouldn't we fix a potential log saturation issue first (by switching
to use dev_err_probe() helper)?
> }
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists