On 11/27/2013 08:50 PM, Sebastian Huber wrote:
Synchronize the program counter before the power down helper call
otherwise interrupts will return to the wrong context.
Signed-off-by: Sebastian Huber <address@hidden>
---
target-sparc/translate.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/target-sparc/translate.c b/target-sparc/translate.c
index 05639ef..7481c85 100644
--- a/target-sparc/translate.c
+++ b/target-sparc/translate.c
@@ -3630,6 +3630,7 @@ static void disas_sparc_insn(DisasContext * dc, unsigned
int insn)
if ((rd == 0x13) && (dc->def->features &
CPU_FEATURE_POWERDOWN)) {
/* LEON3 power-down */
+ save_state(dc);
gen_helper_power_down(cpu_env);
}
break;
Reviewed-by: Richard Henderson <address@hidden>
r~