diff options
author | Tony Luck <tony.luck@intel.com> | 2007-07-20 14:22:30 -0400 |
---|---|---|
committer | Tony Luck <tony.luck@intel.com> | 2007-07-20 14:22:30 -0400 |
commit | 0aa366f351d044703e25c8425e508170e80d83b1 (patch) | |
tree | 485040cbef6157b9bcb2e7b1b85920d1e391ab68 /arch/ia64/kernel/asm-offsets.c | |
parent | 5bae7ac9feba925fd0099057f6b23d7be80b7b41 (diff) |
[IA64] Convert to generic timekeeping/clocksource
This is a merge of Peter Keilty's initial patch (which was
revived by Bob Picco) for this with Hidetoshi Seto's fixes
and scaling improvements.
Acked-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'arch/ia64/kernel/asm-offsets.c')
-rw-r--r-- | arch/ia64/kernel/asm-offsets.c | 35 |
1 files changed, 22 insertions, 13 deletions
diff --git a/arch/ia64/kernel/asm-offsets.c b/arch/ia64/kernel/asm-offsets.c index 2236fabbb3c6..0aebc6f79e95 100644 --- a/arch/ia64/kernel/asm-offsets.c +++ b/arch/ia64/kernel/asm-offsets.c | |||
@@ -7,6 +7,7 @@ | |||
7 | #define ASM_OFFSETS_C 1 | 7 | #define ASM_OFFSETS_C 1 |
8 | 8 | ||
9 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
10 | #include <linux/clocksource.h> | ||
10 | 11 | ||
11 | #include <asm-ia64/processor.h> | 12 | #include <asm-ia64/processor.h> |
12 | #include <asm-ia64/ptrace.h> | 13 | #include <asm-ia64/ptrace.h> |
@@ -15,6 +16,7 @@ | |||
15 | #include <asm-ia64/mca.h> | 16 | #include <asm-ia64/mca.h> |
16 | 17 | ||
17 | #include "../kernel/sigframe.h" | 18 | #include "../kernel/sigframe.h" |
19 | #include "../kernel/fsyscall_gtod_data.h" | ||
18 | 20 | ||
19 | #define DEFINE(sym, val) \ | 21 | #define DEFINE(sym, val) \ |
20 | asm volatile("\n->" #sym " %0 " #val : : "i" (val)) | 22 | asm volatile("\n->" #sym " %0 " #val : : "i" (val)) |
@@ -256,17 +258,24 @@ void foo(void) | |||
256 | BLANK(); | 258 | BLANK(); |
257 | 259 | ||
258 | /* used by fsys_gettimeofday in arch/ia64/kernel/fsys.S */ | 260 | /* used by fsys_gettimeofday in arch/ia64/kernel/fsys.S */ |
259 | DEFINE(IA64_TIME_INTERPOLATOR_ADDRESS_OFFSET, offsetof (struct time_interpolator, addr)); | 261 | DEFINE(IA64_GTOD_LOCK_OFFSET, |
260 | DEFINE(IA64_TIME_INTERPOLATOR_SOURCE_OFFSET, offsetof (struct time_interpolator, source)); | 262 | offsetof (struct fsyscall_gtod_data_t, lock)); |
261 | DEFINE(IA64_TIME_INTERPOLATOR_SHIFT_OFFSET, offsetof (struct time_interpolator, shift)); | 263 | DEFINE(IA64_GTOD_WALL_TIME_OFFSET, |
262 | DEFINE(IA64_TIME_INTERPOLATOR_NSEC_OFFSET, offsetof (struct time_interpolator, nsec_per_cyc)); | 264 | offsetof (struct fsyscall_gtod_data_t, wall_time)); |
263 | DEFINE(IA64_TIME_INTERPOLATOR_OFFSET_OFFSET, offsetof (struct time_interpolator, offset)); | 265 | DEFINE(IA64_GTOD_MONO_TIME_OFFSET, |
264 | DEFINE(IA64_TIME_INTERPOLATOR_LAST_CYCLE_OFFSET, offsetof (struct time_interpolator, last_cycle)); | 266 | offsetof (struct fsyscall_gtod_data_t, monotonic_time)); |
265 | DEFINE(IA64_TIME_INTERPOLATOR_LAST_COUNTER_OFFSET, offsetof (struct time_interpolator, last_counter)); | 267 | DEFINE(IA64_CLKSRC_MASK_OFFSET, |
266 | DEFINE(IA64_TIME_INTERPOLATOR_JITTER_OFFSET, offsetof (struct time_interpolator, jitter)); | 268 | offsetof (struct fsyscall_gtod_data_t, clk_mask)); |
267 | DEFINE(IA64_TIME_INTERPOLATOR_MASK_OFFSET, offsetof (struct time_interpolator, mask)); | 269 | DEFINE(IA64_CLKSRC_MULT_OFFSET, |
268 | DEFINE(IA64_TIME_SOURCE_CPU, TIME_SOURCE_CPU); | 270 | offsetof (struct fsyscall_gtod_data_t, clk_mult)); |
269 | DEFINE(IA64_TIME_SOURCE_MMIO64, TIME_SOURCE_MMIO64); | 271 | DEFINE(IA64_CLKSRC_SHIFT_OFFSET, |
270 | DEFINE(IA64_TIME_SOURCE_MMIO32, TIME_SOURCE_MMIO32); | 272 | offsetof (struct fsyscall_gtod_data_t, clk_shift)); |
271 | DEFINE(IA64_TIMESPEC_TV_NSEC_OFFSET, offsetof (struct timespec, tv_nsec)); | 273 | DEFINE(IA64_CLKSRC_MMIO_OFFSET, |
274 | offsetof (struct fsyscall_gtod_data_t, clk_fsys_mmio)); | ||
275 | DEFINE(IA64_CLKSRC_CYCLE_LAST_OFFSET, | ||
276 | offsetof (struct fsyscall_gtod_data_t, clk_cycle_last)); | ||
277 | DEFINE(IA64_ITC_JITTER_OFFSET, | ||
278 | offsetof (struct itc_jitter_data_t, itc_jitter)); | ||
279 | DEFINE(IA64_ITC_LASTCYCLE_OFFSET, | ||
280 | offsetof (struct itc_jitter_data_t, itc_lastcycle)); | ||
272 | } | 281 | } |