search for: tsc_shift

Displaying 20 results from an estimated 55 matches for "tsc_shift".

2008 Jul 22
6
[PATCH 0/2] Paravirt loops per jiffy calculation
Hey, Over the last weeks, there has been some discussion regarding paravirt lpj calculation for kvm. Here's my shot at that. KVM hypervisor already put the right value in our pvclock structures, as part of the xen compatibility efforts. So the first patch moves the respective xen code to pvclock.c (since we'll be doing the same calculation anyway), while the second, implements functions
2008 Jul 22
6
[PATCH 0/2] Paravirt loops per jiffy calculation
Hey, Over the last weeks, there has been some discussion regarding paravirt lpj calculation for kvm. Here's my shot at that. KVM hypervisor already put the right value in our pvclock structures, as part of the xen compatibility efforts. So the first patch moves the respective xen code to pvclock.c (since we'll be doing the same calculation anyway), while the second, implements functions
2008 May 08
4
[PATCH 0/4] paravirt clock series.
Respin of the paravirt clock patch series. On the host side the kvm paravirt clock is made compatible with the xen clock. On the guest side some xen code has been factored out into a separate source file shared by both kvm and xen clock implementations. This time it should work ok for kvm smp guests ;) cheers, Gerd
2008 May 08
4
[PATCH 0/4] paravirt clock series.
Respin of the paravirt clock patch series. On the host side the kvm paravirt clock is made compatible with the xen clock. On the guest side some xen code has been factored out into a separate source file shared by both kvm and xen clock implementations. This time it should work ok for kvm smp guests ;) cheers, Gerd
2008 May 16
5
[PATCH 0/4] paravirt clock source patches, #3
paravirt clock source patches, next round, with a bunch of changes in the host code according to Avi's review comments and some minor code tweaks. cheers, Gerd
2008 May 16
5
[PATCH 0/4] paravirt clock source patches, #3
paravirt clock source patches, next round, with a bunch of changes in the host code according to Avi's review comments and some minor code tweaks. cheers, Gerd
2008 Jun 03
10
[PATCH 0/5] paravirt clock source patches, #4
paravirt clock source patches, next round. There is now a pvclock-abi.h file with the structs and some longish comments in it and everybody is switched over to use the stuff in there. cheers, Gerd
2008 Jun 03
10
[PATCH 0/5] paravirt clock source patches, #4
paravirt clock source patches, next round. There is now a pvclock-abi.h file with the structs and some longish comments in it and everybody is switched over to use the stuff in there. cheers, Gerd
2008 Jun 03
6
[PATCH 0/5] paravirt clock source patches, #5
paravirt clock source patches, next round. There is now a pvclock-abi.h file with the structs and some longish comments in it and everybody is switched over to use the stuff in there. Some minor tweaks after super-fast review by Jeremy. The queue is on top of the kvm git tree. The first two patches should have no kvm dependencies and should apply to linus tree just fine. cheers, Gerd
2008 Jun 03
6
[PATCH 0/5] paravirt clock source patches, #5
paravirt clock source patches, next round. There is now a pvclock-abi.h file with the structs and some longish comments in it and everybody is switched over to use the stuff in there. Some minor tweaks after super-fast review by Jeremy. The queue is on top of the kvm git tree. The first two patches should have no kvm dependencies and should apply to linus tree just fine. cheers, Gerd
2018 Oct 11
2
[patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support
...; > > > ktime_get_boot_ns() has frequency correction applied, while > > reading masterclock + TSC offset does not. > > > > So the clock reads differ. > > > > Ah, okay, I finally think I see what's going on. In the kvmclock data > exposed to the guest, tsc_shift and tsc_to_system_mul come from > tgt_tsc_khz, whereas master_kernel_ns and master_cycle_now come from > CLOCK_BOOTTIME. So the kvmclock and kernel clock drift apart at a > rate given by the frequency shift and then suddenly agree again every > time the pvclock data is updated. Yes....
2018 Oct 11
2
[patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support
...; > > > ktime_get_boot_ns() has frequency correction applied, while > > reading masterclock + TSC offset does not. > > > > So the clock reads differ. > > > > Ah, okay, I finally think I see what's going on. In the kvmclock data > exposed to the guest, tsc_shift and tsc_to_system_mul come from > tgt_tsc_khz, whereas master_kernel_ns and master_cycle_now come from > CLOCK_BOOTTIME. So the kvmclock and kernel clock drift apart at a > rate given by the frequency shift and then suddenly agree again every > time the pvclock data is updated. Yes....
2018 Oct 08
2
[patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support
On Mon, Oct 08, 2018 at 10:38:22AM -0700, Andy Lutomirski wrote: > On Mon, Oct 8, 2018 at 8:27 AM Marcelo Tosatti <mtosatti at redhat.com> wrote: > > > > On Sat, Oct 06, 2018 at 03:28:05PM -0700, Andy Lutomirski wrote: > > > On Sat, Oct 6, 2018 at 1:29 PM Marcelo Tosatti <mtosatti at redhat.com> wrote: > > > > > > > > On Thu, Oct 04, 2018
2018 Oct 08
2
[patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support
On Mon, Oct 08, 2018 at 10:38:22AM -0700, Andy Lutomirski wrote: > On Mon, Oct 8, 2018 at 8:27 AM Marcelo Tosatti <mtosatti at redhat.com> wrote: > > > > On Sat, Oct 06, 2018 at 03:28:05PM -0700, Andy Lutomirski wrote: > > > On Sat, Oct 6, 2018 at 1:29 PM Marcelo Tosatti <mtosatti at redhat.com> wrote: > > > > > > > > On Thu, Oct 04, 2018
2007 Mar 26
12
System time monotonicity
...t conclusively proved that. But e.g.: { old = { time = { version = 0x4ec pad0 = 0xe8e0 tsc_timestamp = 0x22cc8398b7194 system_time = 0xe8e0345d8805 tsc_to_system_mul = 0xd62c0083 tsc_shift = ''\377'' pad1 = [ ''\002'', ''\027'', ''\365'' ] } result = 0xe8e0484568fa tsc = 0x22cc86921ab00 cpu = 0 } new = { time = { v...
2007 Aug 30
0
[PATCH][Retry 1] 1/4: cpufreq/PowerNow! in Xen: Xen timer changes
...o, unsigned int old, unsigned int new, int cpu_num) +{ + u64 new_mult, curr_tsc; + s8 new_shift; + struct cpu_time *t; + + t = &this_cpu(cpu_time); + new_mult = info->tsc_to_system_mul; + do_div(new_mult, new / 1000); + new_mult *= (old / 1000); + new_shift = info->tsc_shift; + while (new_mult > (1LL <<32)) { + new_shift += 1; + new_mult = new_mult >> 1; + } + while (new_mult < (1LL << 31)) { + new_shift -= 1; + new_mult = new_mult << 1; + } + + t->tsc_scale.mul_frac = new_mult; + t->tsc...
2018 Oct 09
0
[patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support
...lain how my patch is > > incorrect? > > ktime_get_boot_ns() has frequency correction applied, while > reading masterclock + TSC offset does not. > > So the clock reads differ. > Ah, okay, I finally think I see what's going on. In the kvmclock data exposed to the guest, tsc_shift and tsc_to_system_mul come from tgt_tsc_khz, whereas master_kernel_ns and master_cycle_now come from CLOCK_BOOTTIME. So the kvmclock and kernel clock drift apart at a rate given by the frequency shift and then suddenly agree again every time the pvclock data is updated. Is there a reason to do it...
2018 Oct 11
0
[patch 00/11] x86/vdso: Cleanups, simmplifications and CLOCK_TAI support
...() has frequency correction applied, while > > > reading masterclock + TSC offset does not. > > > > > > So the clock reads differ. > > > > > > > Ah, okay, I finally think I see what's going on. In the kvmclock data > > exposed to the guest, tsc_shift and tsc_to_system_mul come from > > tgt_tsc_khz, whereas master_kernel_ns and master_cycle_now come from > > CLOCK_BOOTTIME. So the kvmclock and kernel clock drift apart at a > > rate given by the frequency shift and then suddenly agree again every > > time the pvclock data...
2008 Jul 04
0
[PATCH] ia64/xen: add a necessary header file to compile include/xen/interface/xen.h
...) when it is done. Thus the guest can make sure the + * time values it got are consistent by checking the version before + * and after reading them. + */ + +struct pvclock_vcpu_time_info { + u32 version; + u32 pad0; + u64 tsc_timestamp; + u64 system_time; + u32 tsc_to_system_mul; + s8 tsc_shift; + u8 pad[3]; +} __attribute__((__packed__)); /* 32 bytes */ + +struct pvclock_wall_clock { + u32 version; + u32 sec; + u32 nsec; +} __attribute__((__packed__)); + +#endif /* __ASSEMBLY__ */ +#endif /* ASM_IA64__PVCLOCK_ABI_H */ -- 1.6.0.2 -- yamahata
2008 Jul 04
0
[PATCH] ia64/xen: add a necessary header file to compile include/xen/interface/xen.h
...) when it is done. Thus the guest can make sure the + * time values it got are consistent by checking the version before + * and after reading them. + */ + +struct pvclock_vcpu_time_info { + u32 version; + u32 pad0; + u64 tsc_timestamp; + u64 system_time; + u32 tsc_to_system_mul; + s8 tsc_shift; + u8 pad[3]; +} __attribute__((__packed__)); /* 32 bytes */ + +struct pvclock_wall_clock { + u32 version; + u32 sec; + u32 nsec; +} __attribute__((__packed__)); + +#endif /* __ASSEMBLY__ */ +#endif /* ASM_IA64__PVCLOCK_ABI_H */ -- 1.6.0.2 -- yamahata