? compile/GENERIC ? conf/NOLOAN Index: cobalt/machdep.c =================================================================== RCS file: /cvsroot/src/sys/arch/cobalt/cobalt/machdep.c,v retrieving revision 1.92 diff -u -r1.92 machdep.c --- cobalt/machdep.c 9 Jan 2008 20:38:35 -0000 1.92 +++ cobalt/machdep.c 12 Mar 2008 12:11:30 -0000 @@ -686,7 +686,9 @@ struct clockframe cf; struct cobalt_intrhand *ih; struct cpu_info *ci; + uint32_t handled; + handled = 0; ci = curcpu(); ci->ci_idepth++; uvmexp.intrs++; @@ -697,9 +699,9 @@ cf.sr = status; mips3_clockintr(&cf); - cause &= ~MIPS_INT_MASK_5; + handled |= MIPS_INT_MASK_5; } - _splset((status & MIPS_INT_MASK_5) | MIPS_SR_INT_IE); + _splset((status & handled) | MIPS_SR_INT_IE); if (__predict_false(ipending & MIPS_INT_MASK_0)) { /* GT64x11 timer0 */ @@ -710,54 +712,56 @@ /* GT64x11 timer is no longer used for hardclock(9) */ *irq_src = 0; } - cause &= ~MIPS_INT_MASK_0; + handled |= MIPS_INT_MASK_0; } - _splset((status & ~cause & MIPS_HARD_INT_MASK) | MIPS_SR_INT_IE); + _splset((status & handled) | MIPS_SR_INT_IE); if (ipending & MIPS_INT_MASK_3) { /* 16650 serial */ ih = &cpu_intrtab[3]; if (__predict_true(ih->ih_func != NULL)) { if (__predict_true((*ih->ih_func)(ih->ih_arg))) { - cause &= ~MIPS_INT_MASK_3; ih->ih_evcnt.ev_count++; } } + handled |= MIPS_INT_MASK_3; } - _splset((status & ~cause & MIPS_HARD_INT_MASK) | MIPS_SR_INT_IE); + _splset((status & handled) | MIPS_SR_INT_IE); if (ipending & MIPS_INT_MASK_1) { /* tulip primary */ ih = &cpu_intrtab[1]; if (__predict_true(ih->ih_func != NULL)) { if (__predict_true((*ih->ih_func)(ih->ih_arg))) { - cause &= ~MIPS_INT_MASK_1; ih->ih_evcnt.ev_count++; } } + handled |= MIPS_INT_MASK_1; } if (ipending & MIPS_INT_MASK_2) { /* tulip secondary */ ih = &cpu_intrtab[2]; if (__predict_true(ih->ih_func != NULL)) { if (__predict_true((*ih->ih_func)(ih->ih_arg))) { - cause &= ~MIPS_INT_MASK_2; ih->ih_evcnt.ev_count++; } } + handled |= MIPS_INT_MASK_2; } - _splset((status & ~cause & MIPS_HARD_INT_MASK) | MIPS_SR_INT_IE); + _splset((status & handled) | MIPS_SR_INT_IE); if (ipending & MIPS_INT_MASK_4) { /* ICU interrupts */ ih = &cpu_intrtab[4]; if (__predict_true(ih->ih_func != NULL)) { if (__predict_true((*ih->ih_func)(ih->ih_arg))) { - cause &= ~MIPS_INT_MASK_4; /* evcnt for ICU is done in icu_intr() */ + ; } } + handled |= MIPS_INT_MASK_4; } + cause &= ~handled; _splset((status & ~cause & MIPS_HARD_INT_MASK) | MIPS_SR_INT_IE); ci->ci_idepth--;