[PATCH v2 3/3] pwm: rockchip: Do not start PWMs not already running

Simon South simon at simonsouth.net
Tue Dec 22 11:32:29 EST 2020


Uwe Kleine-König <u.kleine-koenig at pengutronix.de> writes:
> "starting PWM" here means enabling their clocks, right? I wouldn't
> expect that this has any effect on the output, am I right?

Right, it does not; another misunderstanding on my part. I'll fix the
commit message.

> Just for my understanding: That you moved clk_prepare_enable(pc->pclk)
> further down is not strictly necessary for your change, right?

That's right. My thought was to keep the code that enables this clock
close to the code that relies on it, and to minimize the duration the
clock is enabled.

Would it be better to leave the code where it is?

> I'm not a big fan of this ?: construct...

Neither was I, actually, but I guessed the shorter version would be
preferred. I'm happy to change it back to match what you described.

-- 
Simon South
simon at simonsouth.net



More information about the Linux-rockchip mailing list