All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 3/4] s3c6410: Fix divider value calculation in s3c64xx_roundrate_clksrc
@ 2009-09-08  5:35 ` thomas.ab at samsung.com
  0 siblings, 0 replies; 4+ messages in thread
From: thomas.ab @ 2009-09-08  5:35 UTC (permalink / raw)
  To: ben-linux; +Cc: linux-arm-kernel, linux-mmc, Thomas Abraham

From: Thomas Abraham <thomas.ab@samsung.com>

In s3c64xx_roundrate_clksrc function, the calculation is wrong. This
patch fixes this calculation.

Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
---
 arch/arm/plat-s3c64xx/s3c6400-clock.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/plat-s3c64xx/s3c6400-clock.c b/arch/arm/plat-s3c64xx/s3c6400-clock.c
index 54eef93..9745852 100644
--- a/arch/arm/plat-s3c64xx/s3c6400-clock.c
+++ b/arch/arm/plat-s3c64xx/s3c6400-clock.c
@@ -345,7 +345,7 @@ static unsigned long s3c64xx_roundrate_clksrc(struct clk *clk,
 	if (rate > parent_rate)
 		rate = parent_rate;
 	else {
-		div = rate / parent_rate;
+		div = parent_rate / rate;
 
 		if (div == 0)
 			div = 1;
-- 
1.5.3.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-09-15 23:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-08  5:35 [PATCH 3/4] s3c6410: Fix divider value calculation in s3c64xx_roundrate_clksrc thomas.ab
2009-09-08  5:35 ` thomas.ab at samsung.com
2009-09-15 23:57 ` Ben Dooks
2009-09-15 23:57   ` Ben Dooks

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.