mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-01 06:43:53 -06:00
cpu_loop_exit: avoid using AREG0
Make cpu_loop_exit() take a parameter for CPUState instead of relying on global env. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
This commit is contained in:
parent
4d2c2b77f3
commit
1162c041c1
16 changed files with 57 additions and 56 deletions
11
user-exec.c
11
user-exec.c
|
@ -37,13 +37,14 @@
|
|||
|
||||
//#define DEBUG_SIGNAL
|
||||
|
||||
static void exception_action(CPUState *env1)
|
||||
{
|
||||
#if defined(TARGET_I386)
|
||||
#define EXCEPTION_ACTION \
|
||||
raise_exception_err(env->exception_index, env->error_code)
|
||||
raise_exception_err(env1->exception_index, env1->error_code);
|
||||
#else
|
||||
#define EXCEPTION_ACTION \
|
||||
cpu_loop_exit()
|
||||
cpu_loop_exit(env1);
|
||||
#endif
|
||||
}
|
||||
|
||||
/* exit the current TB from a signal handler. The host registers are
|
||||
restored in a state compatible with the CPU emulator
|
||||
|
@ -118,7 +119,7 @@ static inline int handle_cpu_signal(unsigned long pc, unsigned long address,
|
|||
/* we restore the process signal mask as the sigreturn should
|
||||
do it (XXX: use sigsetjmp) */
|
||||
sigprocmask(SIG_SETMASK, old_set, NULL);
|
||||
EXCEPTION_ACTION;
|
||||
exception_action(env);
|
||||
|
||||
/* never comes here */
|
||||
return 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue