aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel/sched_clock.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-01-15 15:29:50 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2011-01-15 15:29:50 -0500
commit65e5d002b5ad220db2bf9557f53de5a98f7dab86 (patch)
tree93d36afd4b82a24e5b553766a574a6632fca3aff /arch/arm/kernel/sched_clock.c
parent38567333a6dabd0f2b4150e9fb6dd8e3ba2985e5 (diff)
parentcb4d3eaebb96616085f5a46a7d7e004ddd955b09 (diff)
Merge branch 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm: ARM: fix missing branch in __error_a ARM: fix /proc/$PID/stack on SMP ARM: Fix build regression on SA11x0, PXA, and H720x targets ARM: 6625/1: use memblock memory regions for "System RAM" I/O resources ARM: fix wrongly patched constants ARM: 6624/1: fix dependency for CONFIG_SMP_ON_UP ARM: 6623/1: Thumb-2: Fix out-of-range offset for Thumb-2 in proc-v7.S ARM: 6622/1: fix dma_unmap_sg() documentation ARM: 6621/1: bitops: remove condition code clobber for CLZ ARM: 6620/1: Change misleading warning when CONFIG_CMDLINE_FORCE is used ARM: 6619/1: nommu: avoid mapping vectors page when !CONFIG_MMU ARM: sched_clock: make minsec argument to clocks_calc_mult_shift() zero ARM: sched_clock: allow init_sched_clock() to be called early ARM: integrator: fix compile warning in cpu.c ARM: 6616/1: Fix ep93xx-fb init/exit annotations ARM: twd: fix display of twd frequency ARM: udelay: prevent math rounding resulting in short udelays
Diffstat (limited to 'arch/arm/kernel/sched_clock.c')
-rw-r--r--arch/arm/kernel/sched_clock.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/arch/arm/kernel/sched_clock.c b/arch/arm/kernel/sched_clock.c
index 2cdcc9287c74..9a46370fe9da 100644
--- a/arch/arm/kernel/sched_clock.c
+++ b/arch/arm/kernel/sched_clock.c
@@ -34,7 +34,7 @@ void __init init_sched_clock(struct clock_data *cd, void (*update)(void),
34 sched_clock_update_fn = update; 34 sched_clock_update_fn = update;
35 35
36 /* calculate the mult/shift to convert counter ticks to ns. */ 36 /* calculate the mult/shift to convert counter ticks to ns. */
37 clocks_calc_mult_shift(&cd->mult, &cd->shift, rate, NSEC_PER_SEC, 60); 37 clocks_calc_mult_shift(&cd->mult, &cd->shift, rate, NSEC_PER_SEC, 0);
38 38
39 r = rate; 39 r = rate;
40 if (r >= 4000000) { 40 if (r >= 4000000) {
@@ -60,10 +60,15 @@ void __init init_sched_clock(struct clock_data *cd, void (*update)(void),
60 * sets the initial epoch. 60 * sets the initial epoch.
61 */ 61 */
62 sched_clock_timer.data = msecs_to_jiffies(w - (w / 10)); 62 sched_clock_timer.data = msecs_to_jiffies(w - (w / 10));
63 sched_clock_poll(sched_clock_timer.data); 63 update();
64 64
65 /* 65 /*
66 * Ensure that sched_clock() starts off at 0ns 66 * Ensure that sched_clock() starts off at 0ns
67 */ 67 */
68 cd->epoch_ns = 0; 68 cd->epoch_ns = 0;
69} 69}
70
71void __init sched_clock_postinit(void)
72{
73 sched_clock_poll(sched_clock_timer.data);
74}