From: Sangbeom Kim Date: Fri, 9 Mar 2012 07:28:10 +0000 (+0900) Subject: regulator: Fix s5m8767_set_voltage_time_sel calculation value X-Git-Tag: accepted/tizen/common/20141203.182822~4902^2~21^2~18 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0f8b9c774442fa0ada36e5a0de9567588cc964cd;p=platform%2Fkernel%2Flinux-arm64.git regulator: Fix s5m8767_set_voltage_time_sel calculation value In the s5m8767_set_voltage_time_sel function, divisor unit is wrong. ramp_delay is usec unit. So 1000 should be multiplied. Signed-off-by: Sangbeom Kim Signed-off-by: Mark Brown --- diff --git a/drivers/regulator/s5m8767.c b/drivers/regulator/s5m8767.c index e369d9e..3592ccb 100644 --- a/drivers/regulator/s5m8767.c +++ b/drivers/regulator/s5m8767.c @@ -457,7 +457,7 @@ static int s5m8767_set_voltage_time_sel(struct regulator_dev *rdev, if (old_sel < new_sel) return DIV_ROUND_UP(desc->step * (new_sel - old_sel), - s5m8767->ramp_delay); + s5m8767->ramp_delay * 1000); return 0; }