This is the mail archive of the
ecos-patches@sources.redhat.com
mailing list for the eCos project.
Fix for bug 1000106: IDT32334 int loop refinement
- From: Jonathan Larmour <jlarmour at jifvik dot org>
- To: ecos-patches at ecos dot sourceware dot org
- Date: Sat, 31 Jul 2004 00:42:04 +0100
- Subject: Fix for bug 1000106: IDT32334 int loop refinement
Index: ChangeLog
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/mips/idt32334/current/ChangeLog,v
retrieving revision 1.5
diff -u -5 -p -r1.5 ChangeLog
--- ChangeLog 22 Apr 2004 15:26:40 -0000 1.5
+++ ChangeLog 30 Jul 2004 23:42:03 -0000
@@ -1,5 +1,10 @@
+2004-07-31 Jonathan Larmour <jifl@eCosCentric.com>
+
+ * src/var_intr.c (hal_extended_isr): Only need to check bits 1 to 14.
+ Fix for bug #1000106.
+
2004-04-22 Jani Monoses <jani@iv.ro>
* cdl/hal_mips_idt32334.cdl :
Invoke tail with stricter syntax that works in latest coreutils.
Index: src/var_intr.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/mips/idt32334/current/src/var_intr.c,v
retrieving revision 1.2
diff -u -5 -p -r1.2 var_intr.c
--- src/var_intr.c 29 Apr 2003 02:33:05 -0000 1.2
+++ src/var_intr.c 30 Jul 2004 23:42:03 -0000
@@ -187,11 +187,13 @@ hal_extended_isr(CYG_ADDRWORD vector, CY
cyg_uint32 isrNum;
HAL_READ_UINT32 (INTR_STATUS_PTR, pendingIsr);
- for (isrNum=0; isrNum <=31; isrNum++)
+ // Although we could check 32-bits of the register, according
+ // to the IDT32334 docs, only bits 1 to 14 are actually used.
+ for (isrNum=1; isrNum <=14; isrNum++)
if ( (1 << isrNum) & pendingIsr)
break;
if (pendingIsr) {
isrRet = hal_call_isr (CYGNUM_LAST_IDT_INTERRUPT + isrNum);