xref: /netbsd/sys/arch/acorn32/doc/interrupts (revision 6550d01e)
1/* $NetBSD: interrupts,v 1.1 2001/10/18 00:05:01 reinoud Exp $ */
2
3/*
4 * Copyright (c) 1996 Mark Brinicombe.
5 * All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions
9 * are met:
10 * 1. Redistributions of source code must retain the above copyright
11 *    notice, this list of conditions and the following disclaimer.
12 * 2. Redistributions in binary form must reproduce the above copyright
13 *    notice, this list of conditions and the following disclaimer in the
14 *    documentation and/or other materials provided with the distribution.
15 * 3. All advertising materials mentioning features or use of this software
16 *    must display the following acknowledgement:
17 *	This product includes software developed by Mark Brinicombe.
18 * 4. The name of the company nor the name of the author may be used to
19 *    endorse or promote products derived from this software without specific
20 *    prior written permission.
21 *
22 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
23 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
24 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
25 * IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
26 * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
27 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
28 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 * SUCH DAMAGE.
33 */
34
35Notes on interrupts.
36
37Ok since interrupts can be chained the return value from an interrupt
38handler is important.
39
40The following return values are defined :
41
42-1	- interrupt may have been for us but not sure so pass it on
430	- interrupt no serviced (not ours)
44	  interrupt serviced but pass on down the chain
451	- interrupt serviced do not pass on down the chain
46
47The important bit is whether the interrupt should be passed on down
48the chain of attached interrupt handlers.
49
50For some interrupts and drivers where only a single device is
51ever expected, the interrupt should be claimed if it has been serviced.
52Passing it on down the chain may result in the stray interrupt handler
53being called.
54There are however some interrupt that should *always* be passed on down
55the chain. These are interrupt which may commonly have multiple drivers
56attached.
57
58The following interrupts should always be passed on (return value of 0)
59
60IRQ_TIMER0
61IRQ_TIMER1
62IRQ_VSYNC
63IRQ_FLYBACK
64IRQ_PODULE
65
66IRQ_CLOCK	(RC7500)
67
68The following interrupts are recommended to be passed on
69
70IRQ_DMACH0
71IRQ_DMACH1
72IRQ_DMACH2
73IRQ_DMACH3
74IRQ_DMASCH0
75IRQ_DMASCH1
76
77IRQ_SDMA	(RC7500)
78
79All other interrupts are not expected to be shared and may be claimed
80when serviced. Stray IRQ handlers may or may not be attached to the end
81of these irq chains.
82