1
2
3
4
5
6
7
8
9
10
11
12
13
14 #ifndef __ASM_DEC_INTERRUPTS_H
15 #define __ASM_DEC_INTERRUPTS_H
16
17 #include <irq.h>
18 #include <asm/mipsregs.h>
19
20
21
22
23
24
25 #define DEC_IRQ_CASCADE 0
26
27
28 #define DEC_IRQ_AB_RECV 1
29 #define DEC_IRQ_AB_XMIT 2
30 #define DEC_IRQ_DZ11 3
31 #define DEC_IRQ_ASC 4
32 #define DEC_IRQ_FLOPPY 5
33 #define DEC_IRQ_FPU 6
34 #define DEC_IRQ_HALT 7
35 #define DEC_IRQ_ISDN 8
36 #define DEC_IRQ_LANCE 9
37 #define DEC_IRQ_BUS 10
38 #define DEC_IRQ_PSU 11
39 #define DEC_IRQ_RTC 12
40 #define DEC_IRQ_SCC0 13
41 #define DEC_IRQ_SCC1 14
42 #define DEC_IRQ_SII 15
43 #define DEC_IRQ_TC0 16
44 #define DEC_IRQ_TC1 17
45 #define DEC_IRQ_TC2 18
46 #define DEC_IRQ_TIMER 19
47 #define DEC_IRQ_VIDEO 20
48
49
50 #define DEC_IRQ_ASC_MERR 21
51 #define DEC_IRQ_ASC_ERR 22
52 #define DEC_IRQ_ASC_DMA 23
53 #define DEC_IRQ_FLOPPY_ERR 24
54 #define DEC_IRQ_ISDN_ERR 25
55 #define DEC_IRQ_ISDN_RXDMA 26
56 #define DEC_IRQ_ISDN_TXDMA 27
57 #define DEC_IRQ_LANCE_MERR 28
58 #define DEC_IRQ_SCC0A_RXERR 29
59 #define DEC_IRQ_SCC0A_RXDMA 30
60 #define DEC_IRQ_SCC0A_TXERR 31
61 #define DEC_IRQ_SCC0A_TXDMA 32
62 #define DEC_IRQ_AB_RXERR 33
63 #define DEC_IRQ_AB_RXDMA 34
64 #define DEC_IRQ_AB_TXERR 35
65 #define DEC_IRQ_AB_TXDMA 36
66 #define DEC_IRQ_SCC1A_RXERR 37
67 #define DEC_IRQ_SCC1A_RXDMA 38
68 #define DEC_IRQ_SCC1A_TXERR 39
69 #define DEC_IRQ_SCC1A_TXDMA 40
70
71
72 #define DEC_IRQ_TC5 DEC_IRQ_ASC
73 #define DEC_IRQ_TC6 DEC_IRQ_LANCE
74
75 #define DEC_NR_INTS 41
76
77
78
79 #define DEC_MAX_CPU_INTS 6
80
81 #define DEC_MAX_ASIC_INTS 9
82
83
84
85
86
87 #define DEC_CPU_INR_FPU 7
88 #define DEC_CPU_INR_SW1 1
89 #define DEC_CPU_INR_SW0 0
90
91 #define DEC_CPU_IRQ_BASE MIPS_CPU_IRQ_BASE
92
93 #define DEC_CPU_IRQ_NR(n) ((n) + DEC_CPU_IRQ_BASE)
94 #define DEC_CPU_IRQ_MASK(n) (1 << ((n) + CAUSEB_IP))
95 #define DEC_CPU_IRQ_ALL (0xff << CAUSEB_IP)
96
97
98 #ifndef __ASSEMBLY__
99
100
101
102
103 typedef union { int i; void *p; } int_ptr;
104 extern int dec_interrupt[DEC_NR_INTS];
105 extern int_ptr cpu_mask_nr_tbl[DEC_MAX_CPU_INTS][2];
106 extern int_ptr asic_mask_nr_tbl[DEC_MAX_ASIC_INTS][2];
107 extern int cpu_fpu_mask;
108
109
110
111
112
113 extern void kn02_io_int(void);
114 extern void kn02xa_io_int(void);
115 extern void kn03_io_int(void);
116 extern void asic_dma_int(void);
117 extern void asic_all_int(void);
118 extern void kn02_all_int(void);
119 extern void cpu_all_int(void);
120
121 extern void dec_intr_unimplemented(void);
122 extern void asic_intr_unimplemented(void);
123
124 #endif
125
126 #endif