@@ -28,7 +28,7 @@ void cpu_loop_exit(CPUArchState *env)
2828 CPUState * cpu = ENV_GET_CPU (env );
2929
3030 cpu -> current_tb = NULL ;
31- siglongjmp (env -> jmp_env , 1 );
31+ siglongjmp (cpu -> jmp_env , 1 );
3232}
3333
3434/* exit the current TB from a signal handler. The host registers are
@@ -37,10 +37,12 @@ void cpu_loop_exit(CPUArchState *env)
3737#if defined(CONFIG_SOFTMMU )
3838void cpu_resume_from_signal (CPUArchState * env , void * puc )
3939{
40+ CPUState * cpu = ENV_GET_CPU (env );
41+
4042 /* XXX: restore cpu registers saved in host registers */
4143
4244 env -> exception_index = -1 ;
43- siglongjmp (env -> jmp_env , 1 );
45+ siglongjmp (cpu -> jmp_env , 1 );
4446}
4547#endif
4648
@@ -284,7 +286,7 @@ int cpu_exec(CPUArchState *env)
284286
285287 /* prepare setjmp context for exception handling */
286288 for (;;) {
287- if (sigsetjmp (env -> jmp_env , 0 ) == 0 ) {
289+ if (sigsetjmp (cpu -> jmp_env , 0 ) == 0 ) {
288290 /* if an exception is pending, we execute it here */
289291 if (env -> exception_index >= 0 ) {
290292 if (env -> exception_index >= EXCP_INTERRUPT ) {
0 commit comments