Commit e9bc4411 authored by Florian Fainelli's avatar Florian Fainelli Committed by Thierry Reding

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: 3a9f5957 ("pwm: Add Broadcom BCM7038 PWM controller support")
Signed-off-by: default avatarFlorian Fainelli <florian.fainelli@broadcom.com>
Acked-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: default avatarThierry Reding <thierry.reding@gmail.com>
parent 87e51b76
......@@ -264,7 +264,7 @@ static int brcmstb_pwm_suspend(struct device *dev)
{
struct brcmstb_pwm *p = dev_get_drvdata(dev);
clk_disable(p->clk);
clk_disable_unprepare(p->clk);
return 0;
}
......@@ -273,7 +273,7 @@ static int brcmstb_pwm_resume(struct device *dev)
{
struct brcmstb_pwm *p = dev_get_drvdata(dev);
clk_enable(p->clk);
clk_prepare_enable(p->clk);
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment