Skip to content

Commit 59921a7

Browse files
Liu YingUwe Kleine-König
authored andcommitted
pwm: adp5585: Set OSC_EN bit to 1 when PWM state is enabled
It turns out that OSC_EN bit in GERNERAL_CFG register has to be set to 1 when PWM state is enabled, otherwise PWM signal won't be generated. Fixes: e9b5038 ("pwm: adp5585: Add Analog Devices ADP5585 support") Signed-off-by: Liu Ying <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Uwe Kleine-König <[email protected]>
1 parent 4c82005 commit 59921a7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/pwm/pwm-adp5585.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,10 @@ static int pwm_adp5585_apply(struct pwm_chip *chip,
100100
if (ret)
101101
return ret;
102102

103+
ret = regmap_set_bits(regmap, ADP5585_GENERAL_CFG, ADP5585_OSC_EN);
104+
if (ret)
105+
return ret;
106+
103107
return regmap_set_bits(regmap, ADP5585_PWM_CFG, ADP5585_PWM_EN);
104108
}
105109

0 commit comments

Comments
 (0)