On Thu, Sep 04, 2014 at 07:44:51PM +0200, Paolo Bonzini wrote:
Il 04/09/2014 17:05, Gleb Natapov ha scritto:
If you do that, KVM gets down to the if (writeback) and writes the
ctxt-eip from L2 into the L1 EIP.
Heh, that's a bummer. We should not write back if an instruction caused a
On Tue, Sep 02, 2014 at 05:13:49PM +0200, Paolo Bonzini wrote:
This is required for the following patch to work correctly. If a nested page
fault happens during emulation, we must inject a vmexit, not a page fault.
Luckily we already have the required machinery: it is enough to return
Il 04/09/2014 09:02, Gleb Natapov ha scritto:
On Tue, Sep 02, 2014 at 05:13:49PM +0200, Paolo Bonzini wrote:
This is required for the following patch to work correctly. If a nested
page
fault happens during emulation, we must inject a vmexit, not a page fault.
Luckily we already have
On Thu, Sep 04, 2014 at 04:12:19PM +0200, Paolo Bonzini wrote:
Il 04/09/2014 09:02, Gleb Natapov ha scritto:
On Tue, Sep 02, 2014 at 05:13:49PM +0200, Paolo Bonzini wrote:
This is required for the following patch to work correctly. If a nested
page
fault happens during emulation, we
Il 04/09/2014 17:05, Gleb Natapov ha scritto:
if (ctxt-have_exception) {
inject_emulated_exception(vcpu);
- r = EMULATE_DONE;
+ return EMULATE_DONE;
If there was no vmexit we still want to writeback. Perhaps:
writeback =
Il 04/09/2014 17:05, Gleb Natapov ha scritto:
If you do that, KVM gets down to the if (writeback) and writes the
ctxt-eip from L2 into the L1 EIP.
Heh, that's a bummer. We should not write back if an instruction caused a
vmexit.
You're right, that works.
Paolo
-- 8
This is required for the following patch to work correctly. If a nested page
fault happens during emulation, we must inject a vmexit, not a page fault.
Luckily we already have the required machinery: it is enough to return
X86EMUL_INTERCEPTED instead of X86EMUL_PROPAGATE_FAULT.
Reported-by: