Skip to content

Commit e9bc441

Browse files
ffainellithierryreding
authored andcommitted
pwm: brcmstb: Utilize appropriate clock APIs in suspend/resume
The suspend/resume functions currently utilize clk_disable()/clk_enable() respectively which may be no-ops with certain clock providers such as SCMI. Fix this to use clk_disable_unprepare() and clk_prepare_enable() respectively as we should. Fixes: 3a9f595 ("pwm: Add Broadcom BCM7038 PWM controller support") Signed-off-by: Florian Fainelli <[email protected]> Acked-by: Uwe Kleine-König <[email protected]> Signed-off-by: Thierry Reding <[email protected]>
1 parent 87e51b7 commit e9bc441

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/pwm/pwm-brcmstb.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ static int brcmstb_pwm_suspend(struct device *dev)
264264
{
265265
struct brcmstb_pwm *p = dev_get_drvdata(dev);
266266

267-
clk_disable(p->clk);
267+
clk_disable_unprepare(p->clk);
268268

269269
return 0;
270270
}
@@ -273,7 +273,7 @@ static int brcmstb_pwm_resume(struct device *dev)
273273
{
274274
struct brcmstb_pwm *p = dev_get_drvdata(dev);
275275

276-
clk_enable(p->clk);
276+
clk_prepare_enable(p->clk);
277277

278278
return 0;
279279
}

0 commit comments

Comments
 (0)