aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/hrtimer.c
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2007-02-16 04:28:00 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-16 11:13:59 -0500
commitd316c57ff6bfad9557462b9100f25c6260d2b774 (patch)
treef77a04aab5c39c416f52ff5ac9396da5a6b93759 /kernel/hrtimer.c
parente05d723f98595b2f4d368f63636a997d98703304 (diff)
[PATCH] clockevents: add core functionality
Architectures register their clock event devices, in the clock events core. Users of the clockevents core can get clock event devices for their use. The clockevents core code provides notification mechanisms for various clock related management events. This allows to control the clock event devices without the architectures having to worry about the details of function assignment. This is also a preliminary for high resolution timers and dynamic ticks to allow the core code to control the clock functionality without intrusive changes to the architecture code. [Fixes-by: Ingo Molnar <mingo@elte.hu>] Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@elte.hu> Cc: Roman Zippel <zippel@linux-m68k.org> Cc: john stultz <johnstul@us.ibm.com> Cc: Andi Kleen <ak@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/hrtimer.c')
-rw-r--r--kernel/hrtimer.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c
index eca0f5593a75..a2310d1bebe1 100644
--- a/kernel/hrtimer.c
+++ b/kernel/hrtimer.c
@@ -46,7 +46,7 @@
46 * 46 *
47 * returns the time in ktime_t format 47 * returns the time in ktime_t format
48 */ 48 */
49static ktime_t ktime_get(void) 49ktime_t ktime_get(void)
50{ 50{
51 struct timespec now; 51 struct timespec now;
52 52
@@ -60,7 +60,7 @@ static ktime_t ktime_get(void)
60 * 60 *
61 * returns the time in ktime_t format 61 * returns the time in ktime_t format
62 */ 62 */
63static ktime_t ktime_get_real(void) 63ktime_t ktime_get_real(void)
64{ 64{
65 struct timespec now; 65 struct timespec now;
66 66
@@ -311,14 +311,6 @@ static unsigned long ktime_divns(const ktime_t kt, s64 div)
311#endif /* BITS_PER_LONG >= 64 */ 311#endif /* BITS_PER_LONG >= 64 */
312 312
313/* 313/*
314 * Timekeeping resumed notification
315 */
316void hrtimer_notify_resume(void)
317{
318 clock_was_set();
319}
320
321/*
322 * Counterpart to lock_timer_base above: 314 * Counterpart to lock_timer_base above:
323 */ 315 */
324static inline 316static inline
@@ -889,6 +881,7 @@ static int __cpuinit hrtimer_cpu_notify(struct notifier_block *self,
889 881
890#ifdef CONFIG_HOTPLUG_CPU 882#ifdef CONFIG_HOTPLUG_CPU
891 case CPU_DEAD: 883 case CPU_DEAD:
884 clockevents_notify(CLOCK_EVT_NOTIFY_CPU_DEAD, &cpu);
892 migrate_hrtimers(cpu); 885 migrate_hrtimers(cpu);
893 break; 886 break;
894#endif 887#endif