Linux 3.8-rc7
[cris-mirror.git] / arch / x86 / kernel / trace_clock.c
blob25b993729f9be68db72617d8dc84cb58d710b52e
1 /*
2 * X86 trace clocks
3 */
4 #include <asm/trace_clock.h>
5 #include <asm/barrier.h>
6 #include <asm/msr.h>
8 /*
9 * trace_clock_x86_tsc(): A clock that is just the cycle counter.
11 * Unlike the other clocks, this is not in nanoseconds.
13 u64 notrace trace_clock_x86_tsc(void)
15 u64 ret;
17 rdtsc_barrier();
18 rdtscll(ret);
20 return ret;