diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-01 16:48:25 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-01 16:48:25 (GMT) |
commit | e56425b135a8892d1e71ad5bb605d12c10efeb32 (patch) | |
tree | 9bb899e1b6b45a125bcc21554f3673878d932035 /kernel/time/clocksource.c | |
parent | 786f8ba2e9449a7f01ec6bc35838d0a335921061 (diff) | |
parent | 6622e670b26fbaa9c4ae7772a4d2d0abd3414b51 (diff) | |
download | linux-fsl-qoriq-e56425b135a8892d1e71ad5bb605d12c10efeb32.tar.xz |
Merge branch 'timers-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'timers-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
posix-timers.c: Don't export local functions
clocksource: start CMT at clocksource resume
clocksource: add suspend callback
clocksource: add argument to resume callback
ntp: Cleanup xtime references in ntp.c
ntp: Make time_esterror and time_maxerror static
Diffstat (limited to 'kernel/time/clocksource.c')
-rw-r--r-- | kernel/time/clocksource.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c index 1370083..1f663d2 100644 --- a/kernel/time/clocksource.c +++ b/kernel/time/clocksource.c @@ -453,6 +453,18 @@ static inline int clocksource_watchdog_kthread(void *data) { return 0; } #endif /* CONFIG_CLOCKSOURCE_WATCHDOG */ /** + * clocksource_suspend - suspend the clocksource(s) + */ +void clocksource_suspend(void) +{ + struct clocksource *cs; + + list_for_each_entry_reverse(cs, &clocksource_list, list) + if (cs->suspend) + cs->suspend(cs); +} + +/** * clocksource_resume - resume the clocksource(s) */ void clocksource_resume(void) @@ -461,7 +473,7 @@ void clocksource_resume(void) list_for_each_entry(cs, &clocksource_list, list) if (cs->resume) - cs->resume(); + cs->resume(cs); clocksource_resume_watchdog(); } |