Signed-off-by: Philippe Mathieu-Daudé <[email protected]>
---
target/i386/hvf/hvf.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/target/i386/hvf/hvf.c b/target/i386/hvf/hvf.c
index de5e8b45d19..8acdfa952c1 100644
--- a/target/i386/hvf/hvf.c
+++ b/target/i386/hvf/hvf.c
@@ -724,6 +724,10 @@ void hvf_simulate_wrmsr(CPUState *cs)
void hvf_arch_cpu_synchronize_pre_exec(CPUState *cpu)
{
+ if (cpu->vcpu_dirty) {
+ hvf_arch_put_registers(cpu);
+ cpu->vcpu_dirty = false;
+ }
}
void hvf_arch_cpu_synchronize_post_exec(CPUState *cpu)
@@ -983,11 +987,6 @@ int hvf_arch_vcpu_exec(CPUState *cpu)
}
do {
- if (cpu->vcpu_dirty) {
- hvf_arch_put_registers(cpu);
- cpu->vcpu_dirty = false;
- }
-
if (hvf_inject_interrupts(cpu)) {
return EXCP_INTERRUPT;
}
--
2.51.0