]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commit
OMAP2/3 GPTIMER: allow system tick GPTIMER to be changed in board-*.c files
authorPaul Walmsley <paul@pwsan.com>
Fri, 10 Apr 2009 16:38:55 +0000 (10:38 -0600)
committerpaul <paul@twilight.(none)>
Fri, 10 Apr 2009 16:38:55 +0000 (10:38 -0600)
commit5f151be8387a63e60a2bbd2a61f2d2561c70532c
treeda4de14719169be1df9483f7270430bf019b5e6c
parent6ac206c85233eb89533647f5fdc5ebe07320c5e5
OMAP2/3 GPTIMER: allow system tick GPTIMER to be changed in board-*.c files

Add a function omap2_gp_clockevent_set_gptimer() for board-*.c files
to use in .init_irq functions to configure the system tick GPTIMER.
Practical choices at this point are GPTIMER1 or GPTIMER12.  Both of
these timers are in the WKUP powerdomain, and so are unaffected by
chip power management.  GPTIMER1 can use sys_clk as a source, for
applications where a high-resolution timer is more important than
power management.  GPTIMER12 has the special property that it has the
secure 32kHz oscillator as its source clock, which may be less prone
to glitches than the off-chip 32kHz oscillator.  But on HS devices, it
may not be available for Linux use.

It appears that most boards are fine with GPTIMER1, but BeagleBoard
should use GPTIMER12 when using a 32KiHz timer source, due to hardware bugs
in revisions B4 and below.  Modify board-omap3beagle.c to use GPTIMER12.

This patch originally used a Kbuild config option to select the GPTIMER,
but was changed to allow this to be specified in board-*.c files, per
Tony's request.

Tested on Beagle rev B4 ES2.1, with and without CONFIG_OMAP_32K_TIMER, and
3430SDP.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/board-omap3beagle.c
arch/arm/mach-omap2/clock24xx.c
arch/arm/mach-omap2/clock24xx.h
arch/arm/mach-omap2/clock34xx.h
arch/arm/mach-omap2/timer-gp.c
arch/arm/plat-omap/dmtimer.c
arch/arm/plat-omap/include/mach/dmtimer.h
arch/arm/plat-omap/include/mach/timer-gp.h [new file with mode: 0644]