Re: [patch 2/3] KVM: x86: add option to advance tscdeadline hrtimer expiration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 18/12/2014 13:24, Marcelo Tosatti wrote:
> True. I can change to a direct wait if that is preferred.

What about this:

 	guest_tsc = kvm_x86_ops->read_l1_tsc(vcpu, native_read_tsc());
 	trace_kvm_wait_lapic_expire(vcpu->vcpu_id, guest_tsc - tsc_deadline);
 
	/* We know that __delay is delay_tsc, see kvm_timer_init.  */
 	if (guest_tsc < tsc_deadline)
 		__delay(tsc_deadline - guest_tsc);

and a check in kvm_timer_init:

	if (check_tsc_unstable() && lapic_timer_advance_ns) {
		pr_info("kvm: unstable TSC, disabling lapic_timer_advance_ns\n");
		lapic_timer_advance_ns = 0;
	}

Paolo
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux