From a2417847b68012a6a5e608feeb6bdd36026cc742 Mon Sep 17 00:00:00 2001 From: Diego Ongaro Date: Mon, 20 Apr 2009 16:56:16 -0500 Subject: [PATCH] ioio: save next_rip in kvm_run structure --- sys/kern/kern_fkvm.c | 7 +++---- sys/sys/fkvm.h | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/sys/kern/kern_fkvm.c b/sys/kern/kern_fkvm.c index 9b448788a49..b0875c9a7ab 100644 --- a/sys/kern/kern_fkvm.c +++ b/sys/kern/kern_fkvm.c @@ -2010,7 +2010,8 @@ fkvm_destroy_vm(struct guestvm *guest_vm) } static int -intercept_ioio(struct vcpu *vcpu, struct kvm_run *kvm_run, uint64_t ioio_info, uint64_t rip) +intercept_ioio(struct vcpu *vcpu, struct kvm_run *kvm_run, + uint64_t ioio_info, uint64_t next_rip) { struct vmcb *vmcb = vcpu->vmcb; @@ -2027,9 +2028,7 @@ intercept_ioio(struct vcpu *vcpu, struct kvm_run *kvm_run, uint64_t ioio_info, u kvm_run->u.io.rep = (ioio_info & REP_MASK) >> REP_SHIFT; /* TODO: Research more into Direction Flag checked in KVM; DF bit in RFLAGS */ - /* set the next rip in the VMCB save area for now */ - /* TODO: Store rIP in vm_run structure until we absolutely need it */ - vcpu->regs[VCPU_REGS_RIP] = rip; + kvm_run->u.io.next_rip = next_rip; return 0; } diff --git a/sys/sys/fkvm.h b/sys/sys/fkvm.h index 3a0c921f75d..dffcd04d616 100644 --- a/sys/sys/fkvm.h +++ b/sys/sys/fkvm.h @@ -270,7 +270,7 @@ struct kvm_run { uint8_t string; /* 1 = string */ uint8_t rep; /* repeat boolean */ uint16_t port; - uint32_t count; + uint64_t next_rip; } io; /* KVM_EXIT_MMIO */ -- 2.11.4.GIT