diff options
author | Gleb Natapov <gleb@redhat.com> | 2010-03-18 15:20:06 +0200 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2010-05-17 12:15:59 +0300 |
commit | 063db061b9b3472c925f09ae3a0a8359b80c2295 (patch) | |
tree | b38642f43f436c88ab67c5cadd618596d6e9130a /arch/x86/kvm/x86.c | |
parent | 9c5372445c1ad4fcdb4128957ec89334223b8113 (diff) | |
download | talos-op-linux-063db061b9b3472c925f09ae3a0a8359b80c2295.tar.gz talos-op-linux-063db061b9b3472c925f09ae3a0a8359b80c2295.zip |
KVM: Provide current eip as part of emulator context.
Eliminate the need to call back into KVM to get it from emulator.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'arch/x86/kvm/x86.c')
-rw-r--r-- | arch/x86/kvm/x86.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 9cb28a943c9a..0ecd37ac9d39 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -3531,6 +3531,7 @@ int emulate_instruction(struct kvm_vcpu *vcpu, vcpu->arch.emulate_ctxt.vcpu = vcpu; vcpu->arch.emulate_ctxt.eflags = kvm_x86_ops->get_rflags(vcpu); + vcpu->arch.emulate_ctxt.eip = kvm_rip_read(vcpu); vcpu->arch.emulate_ctxt.mode = (!is_protmode(vcpu)) ? X86EMUL_MODE_REAL : (vcpu->arch.emulate_ctxt.eflags & X86_EFLAGS_VM) |