From: Erwin Authried (eauth@softsys.co.at)
Date: Tue Jul 23 2002 - 10:34:53 EDT
> -----Ursprüngliche Nachricht----- > Von: owner-uclinux-dev@uclinux.org > [mailto:owner-uclinux-dev@uclinux.org]Im Auftrag von Matthias Welwarsky > Gesendet: Dienstag, 23. Juli 2002 15:07 > An: uclinux-dev@uclinux.org > Betreff: Re: [uClinux-dev] ARM external IRQ > > > On Tuesday 23 July 2002 05:46, vincent_kuo@sercomm.com wrote: > > Dear all, > > I am using the TI-TMS320DSC21 EVM board (it's ARM7 CPU). I > meet some > > problems and needs help. > > I know that we could use "request_irq", "enable_irq"... > function calls > > to let the interrrupt run into our interrupt routine. But for > this special > > CPU, it could set its GIO [0-7] as an external interrupt. The CPU has 32 > > GIO [0-31], they are all simply memory I/O, except the first 8 GIO could > > declare both I/O mode and Interrupt mode (GIO[0-7]). > > I'm using the same board btw. You need to enable the EXTBUS > interrupt and map > it to some interrupt handler via request_irq. In this interrupt > handler, you > need to figure which of the GIOs is responsible for the request, > and branch > into the appropriate handler yourself. > > This task is the easier one, because no hassle with assembler code in > entry-armv.S involved. The Atmel AT91 cpus use a similar interrupt system for their 32 pio lines. I found that the interrupt sharing code in the kernel may be (mis-)used in a rather elegant way: First, register a interrupt routine that just clears the status of the PIO interrupt. Then, you can register (and de-register) your own interrupt routines for each of your pio lines as needed. On each pio interrupt, the first registered routine clears the pio interrupt status. Then, all registered interrupt routines are called by the kernel. The only thing that has to be done in every interrupt routine is a check if an interrupt has occured for the pio line, and return immediately if there is no interrupt pending. -Erwin This message resent by the uclinux-dev@uclinux.org list server http://www.uClinux.org/
This archive was generated by hypermail 2.1.4 : Thu Sep 19 2002 - 13:21:35 EDT