diff options
author | bellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162> | 2003-08-20 21:34:35 +0000 |
---|---|---|
committer | bellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162> | 2003-08-20 21:34:35 +0000 |
commit | d05e66d217f8f83487c3b1d3015a67316b47645f (patch) | |
tree | f575ed236e12a05902f835d7d3acf286157297e8 | |
parent | 2d80ae898777a9069e38101b1b53a1347f558838 (diff) | |
download | qemu-d05e66d217f8f83487c3b1d3015a67316b47645f.zip qemu-d05e66d217f8f83487c3b1d3015a67316b47645f.tar.gz qemu-d05e66d217f8f83487c3b1d3015a67316b47645f.tar.bz2 |
no error code if hardware interrupt
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@371 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r-- | cpu-exec.c | 4 | ||||
-rw-r--r-- | exec-i386.h | 2 | ||||
-rw-r--r-- | helper-i386.c | 8 |
3 files changed, 7 insertions, 7 deletions
@@ -170,7 +170,7 @@ int cpu_exec(CPUState *env1) do_interrupt(env->exception_index, env->exception_is_int, env->error_code, - env->exception_next_eip); + env->exception_next_eip, 0); #endif } env->exception_index = -1; @@ -192,7 +192,7 @@ int cpu_exec(CPUState *env1) if (loglevel) { fprintf(logfile, "Servicing hardware INT=0x%02x\n", intno); } - do_interrupt(intno, 0, 0, 0); + do_interrupt(intno, 0, 0, 0, 1); env->interrupt_request &= ~CPU_INTERRUPT_HARD; /* ensure that no TB jump will be modified as the program flow was changed */ diff --git a/exec-i386.h b/exec-i386.h index 03a547f..96ad04e 100644 --- a/exec-i386.h +++ b/exec-i386.h @@ -142,7 +142,7 @@ void tlb_fill(unsigned long addr, int is_write, void *retaddr); void __hidden cpu_lock(void); void __hidden cpu_unlock(void); void do_interrupt(int intno, int is_int, int error_code, - unsigned int next_eip); + unsigned int next_eip, int is_hw); void do_interrupt_user(int intno, int is_int, int error_code, unsigned int next_eip); void raise_interrupt(int intno, int is_int, int error_code, diff --git a/helper-i386.c b/helper-i386.c index fba6b5b..fdbb885 100644 --- a/helper-i386.c +++ b/helper-i386.c @@ -185,7 +185,7 @@ static inline int load_segment(uint32_t *e1_ptr, uint32_t *e2_ptr, /* protected mode interrupt */ static void do_interrupt_protected(int intno, int is_int, int error_code, - unsigned int next_eip) + unsigned int next_eip, int is_hw) { SegmentCache *dt; uint8_t *ptr, *ssp; @@ -265,7 +265,7 @@ static void do_interrupt_protected(int intno, int is_int, int error_code, shift = type >> 3; has_error_code = 0; - if (!is_int) { + if (!is_int && !is_hw) { switch(intno) { case 8: case 10: @@ -427,10 +427,10 @@ void do_interrupt_user(int intno, int is_int, int error_code, * instruction. It is only relevant if is_int is TRUE. */ void do_interrupt(int intno, int is_int, int error_code, - unsigned int next_eip) + unsigned int next_eip, int is_hw) { if (env->cr[0] & CR0_PE_MASK) { - do_interrupt_protected(intno, is_int, error_code, next_eip); + do_interrupt_protected(intno, is_int, error_code, next_eip, is_hw); } else { do_interrupt_real(intno, is_int, error_code, next_eip); } |