lkml.org 
[lkml]   [2019]   [Aug]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH v3 0/2] fix emulation error on Windows bootup
Date
This series intended to fix (again) a bug that was a subject of the 
following change:

6ea6e84 ("KVM: x86: inject exceptions produced by x86_decode_insn")

Suddenly, that fix had a couple mistakes. First, ctxt->have_exception was
not set if fault happened during instruction decoding. Second, returning
value of inject_emulated_instruction was used to make the decision to
reenter guest, but this could happen iff on nested page fault, that is not
the scope where this bug could occur.

v1:
https://lkml.org/lkml/2019/8/27/881

v2:
https://lkml.org/lkml/2019/8/28/879

v3:
- do sanity check in caller code
- drop patch, that moved emulation_type() function

Jan Dakinevich (2):
KVM: x86: always stop emulation on page fault
KVM: x86: set ctxt->have_exception in x86_decode_insn()

arch/x86/kvm/emulate.c | 2 ++
arch/x86/kvm/x86.c | 7 ++++++-
2 files changed, 8 insertions(+), 1 deletion(-)

--
2.1.4

\
 
 \ /
  Last update: 2019-08-29 10:24    [W:0.157 / U:0.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site