[PATCH 0/2] pwm: atmel-hlcdc: Two improvements

Uwe Kleine-König u.kleine-koenig at pengutronix.de
Fri Jan 26 03:59:34 PST 2024


Hello,

while looking through various pwm drivers I found these two
improvements.

The conditional clk_disable_unprepare() in .suspend() makes me wonder if
the PWM continues to operate during suspend. Can someone with the
hardware confirm that? If so, is it really necessary to restore the
registers (by calling atmel_hlcdc_pwm_apply())?

Other drivers have a logic in .suspend() that makes them return -EBUSY
if the pwm is still enabled. So I further wonder if there is an
application for the atmel-hlcdc driver to handle the pwm being enabled
there. Any hints are welcome. I already wondered if it's safe to let the
pwm core return -EBUSY for a suspend request if the hardware is enabled.
So the answer to my question is relevant to this plan, too.

Best regards
Uwe

Uwe Kleine-König (2):
  pwm: atmel-hlcdc: Fix clock imbalance related to suspend support
  pwm: atmel-hlcdc: Don't use pwm consumer API

 drivers/pwm/pwm-atmel-hlcdc.c | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

base-commit: 7be3ba1e5644170feb2cb587860015de97fc7d8a
-- 
2.43.0




More information about the linux-arm-kernel mailing list