summaryrefslogtreecommitdiff
path: root/arch/arm/cpu/armv7/s5p-common/pwm.c
diff options
context:
space:
mode:
authorZhong Hongbo <bocui107@gmail.com>2012-07-02 13:50:49 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-09-01 14:58:23 +0200
commit3936b4f0571b535558ee89038c37a93c1c2c23e6 (patch)
tree868a67a9115ae3173498d032a3d6b6bc66b2ff54 /arch/arm/cpu/armv7/s5p-common/pwm.c
parent42e14f05214399e9362110867207e282b80b7977 (diff)
downloadu-boot-imx-3936b4f0571b535558ee89038c37a93c1c2c23e6.zip
u-boot-imx-3936b4f0571b535558ee89038c37a93c1c2c23e6.tar.gz
u-boot-imx-3936b4f0571b535558ee89038c37a93c1c2c23e6.tar.bz2
arm/s5pxx: Fix get_timer_masked to get the time.
In general, The get_timer_masked function get the system time, no the number of ticks. Such as the nand_wait_ready will use get_timer_masked to delay the operations. And change the system time to adopt to the CONFIG_SYS_HZ. Signed-off-by: Hongbo Zhong <bocui107@gmail.com> Tested-by: Jaehoon Chung<jh80.chung@samsung.com> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
Diffstat (limited to 'arch/arm/cpu/armv7/s5p-common/pwm.c')
-rw-r--r--arch/arm/cpu/armv7/s5p-common/pwm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/cpu/armv7/s5p-common/pwm.c b/arch/arm/cpu/armv7/s5p-common/pwm.c
index 58d279e..44d7bc3 100644
--- a/arch/arm/cpu/armv7/s5p-common/pwm.c
+++ b/arch/arm/cpu/armv7/s5p-common/pwm.c
@@ -170,7 +170,7 @@ int pwm_init(int pwm_id, int div, int invert)
timer_rate_hz = get_pwm_clk() / ((prescaler + 1) *
(div + 1));
- timer_rate_hz = timer_rate_hz / 100;
+ timer_rate_hz = timer_rate_hz / CONFIG_SYS_HZ;
/* set count value */
offset = pwm_id * 3;