This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Bug in i386 interrupt handler
- To: "Ecos-List (E-mail)" <ecos-discuss at sourceware dot cygnus dot com>
- Subject: [ECOS] Bug in i386 interrupt handler
- From: "Phil Hinton" <phil at crosstor dot com>
- Date: Tue, 31 Oct 2000 14:52:28 -0500
Hi,
I've been trying to get SCSII interrupt drivers working on the i386 PC
eCos using the latest tree from anoncvs, plus various patches from
Fabrice (PCI config, multi-thread, etc).
In our implementation, DSR's were being posted for the SCSII interrupt
even though the interrupt handler returns CYG_ISR_HANDLED only.
After further investigation I found a bug in hal_pc_irq
(ecos\packages\hal\i386\arch\current\src\vectors.S).
hal_pc_irq calls the interrupt handler, invokes the hal_intc_ack macro,
then calls interrupt_end.
When the interrupt handler returns, EAX has its returned value, which is
to be passed as an argument to interrupt_end. Since the hal_intc_ack
macro uses the EAX register, it is first stored to ESI by:
movl %eax, %esi
The hal_intc_ack macro then uses EAX, and when interrupt_end is
called:
pushl %edx
pushl %eax
call interrupt_end
Instead this should be:
pushl %edx
pushl %esi <---- modification
call interrupt_end
Did I miss a patch? Anyone having trouble with i386 PC DSR posts?
Phil Hinton
CrosStor Software, Inc.
908-226-0100 ext 138
phil@crosstor.com