Patch: fix init of old_exception
The old_exception field is initialized on startup with 0. Therefore the very first fault (e.g. #GP) could be converted to a double fault on an application processor. The attached patch initialize old_exception on every CPU reset with -1.
Bernhard Kauer
Index: target-i386/helper2.c
===================================================================
RCS file: /sources/qemu/qemu/target-i386/helper2.c,v retrieving revision 1.47
helper2.c +2 -0
@@ -155,6 +155,8 @@tlb_flush (env,1 ); + env->old_exception =-1 ; +/* init to reset state */ #ifdef CONFIG_SOFTMMU