[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] SVM patch to update guest time with latest hvm modifications.
# HG changeset patch # User kaf24@xxxxxxxxxxxxxxxxxxxx # Node ID 48abab2ab71961457d59285bc90fa97958997ec7 # Parent ae6af19f47d3805fd07f320a8d2132963768c67a SVM patch to update guest time with latest hvm modifications. Signed-off-by: Tom Woller <thomas.woller@xxxxxxx> diff -r ae6af19f47d3 -r 48abab2ab719 xen/arch/x86/hvm/svm/intr.c --- a/xen/arch/x86/hvm/svm/intr.c Wed Mar 29 11:02:45 2006 +++ b/xen/arch/x86/hvm/svm/intr.c Wed Mar 29 12:56:26 2006 @@ -81,7 +81,7 @@ } vpit->inject_point = NOW(); - vpit->last_pit_gtime += vpit->period; + vpit->last_pit_gtime += vpit->period_cycles; svm_set_guest_time(v, vpit->last_pit_gtime); } diff -r ae6af19f47d3 -r 48abab2ab719 xen/arch/x86/hvm/svm/svm.c --- a/xen/arch/x86/hvm/svm/svm.c Wed Mar 29 11:02:45 2006 +++ b/xen/arch/x86/hvm/svm/svm.c Wed Mar 29 12:56:26 2006 @@ -674,9 +674,10 @@ { struct hvm_virpit *vpit = &v->domain->arch.hvm_domain.vpit; - v->domain->arch.hvm_domain.guest_time = svm_get_guest_time(v); - if ( vpit->first_injected ) + if ( vpit->first_injected && !v->domain->arch.hvm_domain.guest_time ) { + v->domain->arch.hvm_domain.guest_time = svm_get_guest_time(v); stop_timer(&(vpit->pit_timer)); + } } static void svm_ctxt_switch_from(struct vcpu *v) diff -r ae6af19f47d3 -r 48abab2ab719 xen/arch/x86/hvm/svm/vmcb.c --- a/xen/arch/x86/hvm/svm/vmcb.c Wed Mar 29 11:02:45 2006 +++ b/xen/arch/x86/hvm/svm/vmcb.c Wed Mar 29 12:56:26 2006 @@ -498,8 +498,11 @@ svm_stts(v); /* pick up the elapsed PIT ticks and re-enable pit_timer */ - if ( vpit->first_injected) { - svm_set_guest_time(v, v->domain->arch.hvm_domain.guest_time); + if ( vpit->first_injected ) { + if ( v->domain->arch.hvm_domain.guest_time ) { + svm_set_guest_time(v, v->domain->arch.hvm_domain.guest_time); + v->domain->arch.hvm_domain.guest_time = 0; + } pickup_deactive_ticks(vpit); } @@ -510,7 +513,6 @@ /* We can't resume the guest if we're waiting on I/O */ ASSERT(!test_bit(ARCH_HVM_IO_WAIT, &v->arch.hvm_vcpu.ioflags)); } - void svm_launch_fail(unsigned long eflags) { _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |