@@ -122,11 +142,7 @@
X86CPU *cpu = X86_CPU(cs);
CPUX86State *env = &cpu->env;
- if (retaddr) {
- /* now we have a real cpu fault */
- cpu_restore_state(cs, retaddr);
- }
- raise_exception_err(env, cs->exception_index, env->error_code);
+ raise_exception_err_ra(env, cs->exception_index,
env->error_code, retaddr);
}
}
#endif
The special retaddr condition seems to be part in every other
architecture but not i386. Is there a specific reason ?
The point is - because I'm asking - beginning with qemu 2.5.0. the AMD
SVM virtualization (-cpu phenom) does not work anymore for us. Patching
the vanished retaddr condition back to 2.5.0, 2.8.0 and qemu devel git
branch makes it working again.
From 87e061542205ac56cc485d13607db16239524e4b Mon Sep 17 00:00:00 2001
From: Alexander Boettcher <alexander.boettcher@genode-labs.com>
Date: Thu, 16 Feb 2017 11:17:09 +0100
Subject: [PATCH] x86/tlb_fill: call cpu_restore_state on valid addr
Vanished between 2.4.1 and 2.5.0 release and breaks SVM virtualization.
Signed-off-by: Alexander Boettcher <alexander.boettcher@genode-labs.com>
---
target/i386/mem_helper.c | 4 ++++
1 file changed, 4 insertions(+)
@@ -209,6 +209,10 @@ void tlb_fill(CPUState *cs, target_ulong addr,
MMUAccessType access_type,
X86CPU *cpu = X86_CPU(cs);
CPUX86State *env = &cpu->env;
+ if (retaddr) {
+ /* now we have a real cpu fault */
+ cpu_restore_state(cs, retaddr);
+ }
raise_exception_err_ra(env, cs->exception_index,
env->error_code, retaddr);