The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Sangbeom Kim <sbkim73@samsung.com>
To: linux-kernel@vger.kernel.org, lrg@ti.com,
	"'Mark Brown'" <broonie@opensource.wolfsonmicro.com>
Cc: sbkim01@gmail.com
Subject: [PATCH] regulator: Fix s5m8767_set_voltage_time_sel calculation value
Date: Fri, 09 Mar 2012 16:28:10 +0900	[thread overview]
Message-ID: <06a501ccfdc6$2ded4c60$89c7e520$@com> (raw)

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 <sbkim73@samsung.com>
---
 drivers/regulator/s5m8767.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

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;
 }
 
-- 
1.7.1


             reply	other threads:[~2012-03-09  7:28 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-09  7:28 Sangbeom Kim [this message]
2012-03-09 12:33 ` [PATCH] regulator: Fix s5m8767_set_voltage_time_sel calculation value Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='06a501ccfdc6$2ded4c60$89c7e520$@com' \
    --to=sbkim73@samsung.com \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lrg@ti.com \
    --cc=sbkim01@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox