aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-arm/arch-ixp2000/entry-macro.S
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
commit1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch)
tree0bba044c4ce775e45a88a51686b5d9f90697ea9d /include/asm-arm/arch-ixp2000/entry-macro.S
Linux-2.6.12-rc2
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
Diffstat (limited to 'include/asm-arm/arch-ixp2000/entry-macro.S')
-rw-r--r--include/asm-arm/arch-ixp2000/entry-macro.S53
1 files changed, 53 insertions, 0 deletions
diff --git a/include/asm-arm/arch-ixp2000/entry-macro.S b/include/asm-arm/arch-ixp2000/entry-macro.S
new file mode 100644
index 00000000000..e3a4e412129
--- /dev/null
+++ b/include/asm-arm/arch-ixp2000/entry-macro.S
@@ -0,0 +1,53 @@
1/*
2 * include/asm-arm/arch-ixp2000/entry-macro.S
3 *
4 * Low-level IRQ helper macros for IXP2000-based platforms
5 *
6 * This file is licensed under the terms of the GNU General Public
7 * License version 2. This program is licensed "as is" without any
8 * warranty of any kind, whether express or implied.
9 */
10
11 .macro disable_fiq
12 .endm
13
14 .macro get_irqnr_and_base, irqnr, irqstat, base, tmp
15
16 mov \irqnr, #0x0 @clear out irqnr as default
17 mov \base, #0xfe000000
18 orr \base, \base, #0x00e00000
19 orr \base, \base, #0x08
20 ldr \irqstat, [\base] @ get interrupts
21
22 cmp \irqstat, #0
23 beq 1001f
24
25 clz \irqnr, \irqstat
26 mov \base, #31
27 subs \irqnr, \base, \irqnr
28
29 /*
30 * We handle PCIA and PCIB here so we don't have an
31 * extra layer of code just to check these two bits.
32 */
33 cmp \irqnr, #IRQ_IXP2000_PCI
34 bne 1001f
35
36 mov \base, #0xfe000000
37 orr \base, \base, #0x00c00000
38 orr \base, \base, #0x00000100
39 orr \base, \base, #0x00000058
40 ldr \irqstat, [\base]
41
42 mov \tmp, #(1<<26)
43 tst \irqstat, \tmp
44 movne \irqnr, #IRQ_IXP2000_PCIA
45 bne 1001f
46
47 mov \tmp, #(1<<27)
48 tst \irqstat, \tmp
49 movne \irqnr, #IRQ_IXP2000_PCIB
50
511001:
52 .endm
53