On Thu, Feb 16, 2012 at 03:53:40PM +0200, Avi Kivity wrote:
On 02/16/2012 03:48 PM, Avi Kivity wrote:
The code fixed by the second patch looks suspect though:
nsdiff = data - kvm-arch.last_tsc_write;
nsdiff = (nsdiff * 1000) / vcpu-arch.virtual_tsc_khz;
before the division, nsdiff
The code fixed by the second patch looks suspect though:
nsdiff = data - kvm-arch.last_tsc_write;
nsdiff = (nsdiff * 1000) / vcpu-arch.virtual_tsc_khz;
before the division, nsdiff is in tsc units. Dividing it by
tsc_khz/1000 is equivalent to multiplying it by 100 and dividing it by
On 02/16/2012 03:48 PM, Avi Kivity wrote:
The code fixed by the second patch looks suspect though:
nsdiff = data - kvm-arch.last_tsc_write;
nsdiff = (nsdiff * 1000) / vcpu-arch.virtual_tsc_khz;
before the division, nsdiff is in tsc units. Dividing it by
tsc_khz/1000 is equivalent to