Hello, [dropped Tomislav Denis from Cc: as the address bounces] On Sun, Aug 14, 2022 at 10:01:08PM +0300, Andy Shevchenko wrote: > On Sat, Aug 13, 2022 at 7:21 PM Jonathan Cameron <jic23@xxxxxxxxxx> wrote: > > > > On Mon, 8 Aug 2022 22:47:33 +0200 > > Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> wrote: > > > > > Make use of devm_clk_get_enabled() to replace some code that effectively > > > open codes this new function. > > > > > > Reviewed-by: Andy Shevchenko <andy.shevchenko@xxxxxxxxx> > > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> > > > > This might have side effects as it now enables the clock before calling > > the clk_set_rate(). Also changes the clock start up ordering. Neither is that > > scary a change, but on really fussy hardware they might cause problems. > > > > Add a few rock-chips people who have sent patches in last few years > > to hopefully take a look or even better run a test. > > I believe you found a bug in the patch. The possible solutions are: > - not take the patch > - disable and re-enable clock around clk_set_rate() > > IIRC clk_set_rate() will spit a WARN if clock is enabled. You mean in general? I think that's wrong. There might be some clks that do that, but I'd consider them strange. If you ask me, calling clk_set_rate() for a *disabled* clk is the strange concept ... Best regards Uwe -- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | https://www.pengutronix.de/ |
Attachment:
signature.asc
Description: PGP signature