diff options
-rw-r--r-- | sys/i386/xen/clock.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/i386/xen/clock.c b/sys/i386/xen/clock.c index 5efd66d..03f2517 100644 --- a/sys/i386/xen/clock.c +++ b/sys/i386/xen/clock.c @@ -523,7 +523,8 @@ startrtclock() set_cyc2ns_scale(cpu_khz/1000); tsc_freq = cpu_khz * 1000; - timer_freq = xen_timecounter.tc_frequency = 1000000000LL; + timer_freq = 1000000000LL; + xen_timecounter.tc_frequency = timer_freq >> 9; tc_init(&xen_timecounter); rdtscll(alarm); @@ -830,7 +831,7 @@ xen_get_timecount(struct timecounter *tc) clk = shadow->system_timestamp + get_nsec_offset(shadow); - return (uint32_t)(clk); + return (uint32_t)(clk >> 9); } |