aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace/trace_clock.c
diff options
context:
space:
mode:
authorNamhyung Kim <namhyung.kim@lge.com>2012-12-26 21:49:45 -0500
committerSteven Rostedt <rostedt@goodmis.org>2013-01-30 11:02:05 -0500
commit5e67b51e3fb22ad43faf9589e9019ad9c6a00413 (patch)
tree31e55312ca60e9efa447abdeaeb6ca1546a14673 /kernel/trace/trace_clock.c
parentad964704ba9326d027fc10fd0099b7c880e50172 (diff)
tracing: Use sched_clock_cpu for trace_clock_global
For systems with an unstable sched_clock, all cpu_clock() does is enable/ disable local irq during the call to sched_clock_cpu(). And for stable systems they are same. trace_clock_global() already disables interrupts, so it can call sched_clock_cpu() directly. Link: http://lkml.kernel.org/r/1356576585-28782-2-git-send-email-namhyung@kernel.org Signed-off-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace/trace_clock.c')
-rw-r--r--kernel/trace/trace_clock.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/trace/trace_clock.c b/kernel/trace/trace_clock.c
index 22b638b28e48..24bf48eabfcc 100644
--- a/kernel/trace/trace_clock.c
+++ b/kernel/trace/trace_clock.c
@@ -84,7 +84,7 @@ u64 notrace trace_clock_global(void)
84 local_irq_save(flags); 84 local_irq_save(flags);
85 85
86 this_cpu = raw_smp_processor_id(); 86 this_cpu = raw_smp_processor_id();
87 now = cpu_clock(this_cpu); 87 now = sched_clock_cpu(this_cpu);
88 /* 88 /*
89 * If in an NMI context then dont risk lockups and return the 89 * If in an NMI context then dont risk lockups and return the
90 * cpu_clock() time: 90 * cpu_clock() time: