--- np2/i386c/ia32/exception.c 2004/03/23 15:29:34 1.16 +++ np2/i386c/ia32/exception.c 2005/03/12 12:32:54 1.19 @@ -1,4 +1,4 @@ -/* $Id: exception.c,v 1.16 2004/03/23 15:29:34 monaka Exp $ */ +/* $Id: exception.c,v 1.19 2005/03/12 12:32:54 monaka Exp $ */ /* * Copyright (c) 2003 NONAKA Kimihiro @@ -12,8 +12,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. The name of the author may not be used to endorse or promote products - * derived from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES @@ -72,6 +70,11 @@ exception(int num, int error_code) __ASSERT((unsigned int)num < EXCEPTION_NUM); +#if 0 + iptrace_out(); + debugwriteseg("execption.bin", &CPU_STAT_SREG(CPU_CS_INDEX), CPU_PREV_EIP & 0xffff0000, 0x10000); +#endif + VERBOSE(("exception: -------------------------------------------------------------- start")); VERBOSE(("exception: %s, error_code = %x at %04x:%08x", exception_str[num], error_code, CPU_CS, CPU_PREV_EIP)); VERBOSE(("%s", cpu_reg2str())); @@ -211,8 +214,8 @@ exception(int num, int error_code) * D : ゲートのサイズ.0 = 16 bit, 1 = 32 bit */ -static void interrupt_task_gate(descriptor_t *gd, int softintp, int errorp, int error_code); -static void interrupt_intr_or_trap(descriptor_t *gd, int softintp, int errorp, int error_code); +static void interrupt_task_gate(const descriptor_t *gd, int softintp, int errorp, int error_code); +static void interrupt_intr_or_trap(const descriptor_t *gd, int softintp, int errorp, int error_code); void interrupt(int num, int softintp, int errorp, int error_code) @@ -328,7 +331,7 @@ interrupt(int num, int softintp, int err } static void -interrupt_task_gate(descriptor_t *gd, int softintp, int errorp, int error_code) +interrupt_task_gate(const descriptor_t *gd, int softintp, int errorp, int error_code) { selector_t task_sel; int rv; @@ -373,7 +376,7 @@ interrupt_task_gate(descriptor_t *gd, in } static void -interrupt_intr_or_trap(descriptor_t *gd, int softintp, int errorp, int error_code) +interrupt_intr_or_trap(const descriptor_t *gd, int softintp, int errorp, int error_code) { selector_t cs_sel, ss_sel; UINT stacksize;