Skip to content

Commit

Permalink
clocksource: sh_tmu: Make undefined TCOR behaviour less undefined.
Browse files Browse the repository at this point in the history
Avoid undocumented vague TMU behavior when zero value is set to TCOR.

This primarily fixes up issues encountered under qemu with a zero-length
period, while the hardware itself is fairly ambivalent one way or the
other.

Signed-off-by: Shin-ichiro KAWASAKI <[email protected]>
Acked-by: Magnus Damm <[email protected]>
Signed-off-by: Paul Mundt <[email protected]>
  • Loading branch information
kawasaki authored and pmundt committed Jun 24, 2009
1 parent 4e8a237 commit 6f4b67b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/clocksource/sh_tmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ static void sh_tmu_set_next(struct sh_tmu_priv *p, unsigned long delta,
if (periodic)
sh_tmu_write(p, TCOR, delta);
else
sh_tmu_write(p, TCOR, 0);
sh_tmu_write(p, TCOR, 0xffffffff);

sh_tmu_write(p, TCNT, delta);

Expand Down

0 comments on commit 6f4b67b

Please sign in to comment.