diff options
author | Tony Lindgren <tony@atomide.com> | 2011-03-29 15:54:49 -0700 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2011-06-27 12:14:01 -0700 |
commit | 11a0186f3ef6aa6a9b8b81f5a501b6063fa47500 (patch) | |
tree | cf48a0045d12479cc3a747e35b3b35ed93ba208c /arch/arm/plat-omap/dmtimer.c | |
parent | 98e182a26bbbf5575457622337684ef61493e864 (diff) |
omap2+: Reserve clocksource and timesource and initialize dmtimer later
There's no need to initialize the dmtimer framework early.
Just mark the clocksource and timesource as reserved, and
initialize dmtimer with an arch_initcall.
Signed-off-by: Tony Lindgren <tony@atomide.com>
Reviewed-by: Kevin Hilman <khilman@ti.com>
Diffstat (limited to 'arch/arm/plat-omap/dmtimer.c')
-rw-r--r-- | arch/arm/plat-omap/dmtimer.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/arch/arm/plat-omap/dmtimer.c b/arch/arm/plat-omap/dmtimer.c index 7c5cb4e128f2..8dfb8186b2c2 100644 --- a/arch/arm/plat-omap/dmtimer.c +++ b/arch/arm/plat-omap/dmtimer.c @@ -572,7 +572,7 @@ int omap_dm_timers_active(void) } EXPORT_SYMBOL_GPL(omap_dm_timers_active); -int __init omap_dm_timer_init(void) +static int __init omap_dm_timer_init(void) { struct omap_dm_timer *timer; int i, map_size = SZ_8K; /* Module 4KB + L4 4KB except on omap1 */ @@ -625,8 +625,16 @@ int __init omap_dm_timer_init(void) sprintf(clk_name, "gpt%d_fck", i + 1); timer->fclk = clk_get(NULL, clk_name); } + + /* One or two timers may be set up early for sys_timer */ + if (sys_timer_reserved & (1 << i)) { + timer->reserved = 1; + timer->posted = 1; + } #endif } return 0; } + +arch_initcall(omap_dm_timer_init); |