1 #ifndef _ALPHA_IRQ_H
2 #define _ALPHA_IRQ_H
3
4
5
6
7
8
9
10 #include <linux/linkage.h>
11
12 #include <asm/system.h>
13
14 extern void disable_irq(unsigned int);
15 extern void enable_irq(unsigned int);
16
17
18
19
20
21
22
23
24 struct sun4m_intreg_percpu {
25 unsigned int tbt;
26
27
28
29
30 unsigned int clear;
31 unsigned int set;
32 unsigned char space[PAGE_SIZE - 12];
33 };
34
35 struct sun4m_intregs {
36 struct sun4m_intreg_percpu cpu_intregs[NCPUS];
37 unsigned int tbt;
38 unsigned int irqs;
39
40
41 unsigned int clear;
42 unsigned int set;
43
44
45 unsigned int undirected_target;
46 };
47
48 extern struct sun4m_intregs *sun4m_interrupts;
49
50
51
52
53
54
55 #define SUN4C_INT_ENABLE 0x01
56 #define SUN4C_INT_E14 0x80
57 #define SUN4C_INT_E10 0x20
58 #define SUN4C_INT_E8 0x10
59 #define SUN4C_INT_E6 0x08
60 #define SUN4C_INT_E4 0x04
61 #define SUN4C_INT_E1 0x02
62
63
64 #define SUN4M_INT_ENABLE 0x80000000
65 #define SUN4M_INT_E14 0x00000080
66 #define SUN4M_INT_E10 0x00080000
67
68 #if 0
69
70
71 #define __STR(x) #x
72 #define STR(x) __STR(x)
73
74 #define SAVE_ALL "xx"
75
76 #define SAVE_MOST "yy"
77
78 #define RESTORE_MOST "zz"
79
80 #define ACK_FIRST(mask) "aa"
81
82 #define ACK_SECOND(mask) "dummy"
83
84 #define UNBLK_FIRST(mask) "dummy"
85
86 #define UNBLK_SECOND(mask) "dummy"
87
88 #define IRQ_NAME2(nr) nr##_interrupt(void)
89 #define IRQ_NAME(nr) IRQ_NAME2(IRQ##nr)
90 #define FAST_IRQ_NAME(nr) IRQ_NAME2(fast_IRQ##nr)
91 #define BAD_IRQ_NAME(nr) IRQ_NAME2(bad_IRQ##nr)
92
93 #define BUILD_IRQ(chip,nr,mask) \
94 asmlinkage void IRQ_NAME(nr); \
95 asmlinkage void FAST_IRQ_NAME(nr); \
96 asmlinkage void BAD_IRQ_NAME(nr); \
97 asm code comes here
98 #endif
99
100 #endif