diff options
author | Andreas Färber | 2013-08-26 08:31:06 +0200 |
---|---|---|
committer | Andreas Färber | 2014-03-13 19:20:46 +0100 |
commit | 27103424c40ce71053c07d8a54ef431365fa9b7f (patch) | |
tree | bec190ce2f52c17d5f5963d743f6c64af47c9240 /target-i386/seg_helper.c | |
parent | cpu: Move jmp_env field from CPU_COMMON to CPUState (diff) | |
download | qemu-27103424c40ce71053c07d8a54ef431365fa9b7f.tar.gz qemu-27103424c40ce71053c07d8a54ef431365fa9b7f.tar.xz qemu-27103424c40ce71053c07d8a54ef431365fa9b7f.zip |
cpu: Move exception_index field from CPU_COMMON to CPUState
Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'target-i386/seg_helper.c')
-rw-r--r-- | target-i386/seg_helper.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/target-i386/seg_helper.c b/target-i386/seg_helper.c index 9dda02d2f1..c8fd572d99 100644 --- a/target-i386/seg_helper.c +++ b/target-i386/seg_helper.c @@ -935,7 +935,9 @@ static void do_interrupt64(CPUX86State *env, int intno, int is_int, #if defined(CONFIG_USER_ONLY) void helper_syscall(CPUX86State *env, int next_eip_addend) { - env->exception_index = EXCP_SYSCALL; + CPUState *cs = CPU(x86_env_get_cpu(env)); + + cs->exception_index = EXCP_SYSCALL; env->exception_next_eip = env->eip + next_eip_addend; cpu_loop_exit(env); } @@ -1248,7 +1250,7 @@ void x86_cpu_do_interrupt(CPUState *cs) /* if user mode only, we simulate a fake exception which will be handled outside the cpu execution loop */ - do_interrupt_user(env, env->exception_index, + do_interrupt_user(env, cs->exception_index, env->exception_is_int, env->error_code, env->exception_next_eip); @@ -1258,7 +1260,7 @@ void x86_cpu_do_interrupt(CPUState *cs) /* simulate a real cpu exception. On i386, it can trigger new exceptions, but we do not handle double or triple faults yet. */ - do_interrupt_all(cpu, env->exception_index, + do_interrupt_all(cpu, cs->exception_index, env->exception_is_int, env->error_code, env->exception_next_eip, 0); |