summaryrefslogtreecommitdiff
path: root/drivers/power/regulator/pwm_regulator.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/power/regulator/pwm_regulator.c')
-rw-r--r--drivers/power/regulator/pwm_regulator.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/power/regulator/pwm_regulator.c b/drivers/power/regulator/pwm_regulator.c
index 00a7cca7f7..fcf5e00837 100644
--- a/drivers/power/regulator/pwm_regulator.c
+++ b/drivers/power/regulator/pwm_regulator.c
@@ -80,7 +80,7 @@ static int pwm_regulator_set_voltage(struct udevice *dev, int uvolt)
}
ret = pwm_set_config(priv->pwm, priv->pwm_id,
- (priv->period_ns / 100) * duty_cycle, priv->period_ns);
+ priv->period_ns, (priv->period_ns / 100) * duty_cycle);
if (ret) {
dev_err(dev, "Failed to configure PWM\n");
return ret;