From 71fcd907205049518e26114fb6d1c08589557809 Mon Sep 17 00:00:00 2001 From: pbrook Date: Fri, 19 Dec 2008 12:49:13 +0000 Subject: [PATCH] When -icount is used and a TB is recompiled due to an IO access shortly after an IRQ has been raised, env->exception_index will still be set to EXCP_IRQ when cpu_io_recompile calls cpu_resume_from_signal. This causes qemu to repeat the IRQ trap, with disasterous consequences. I suspect this "works" most of the time because linux tends to drop back to svc mode before doing actual IRQ processing, and be fairly tolerant of spurious IRQ traps. Signed-off-by: Paul Brook git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6100 c046a42c-6fe2-441c-8c8c-71466251a162 --- cpu-exec.c | 1 + 1 file changed, 1 insertion(+) diff --git a/cpu-exec.c b/cpu-exec.c index ed1545b..0a49a7e 100644 --- a/cpu-exec.c +++ b/cpu-exec.c @@ -86,6 +86,7 @@ void cpu_resume_from_signal(CPUState *env1, void *puc) #endif } #endif + env->exception_index = -1; longjmp(env->jmp_env, 1); } -- 2.7.4