diff options
Diffstat (limited to 'arch/mips/lasat/interrupt.c')
-rw-r--r-- | arch/mips/lasat/interrupt.c | 36 |
1 files changed, 6 insertions, 30 deletions
diff --git a/arch/mips/lasat/interrupt.c b/arch/mips/lasat/interrupt.c index a144a002dcc4..cac82afe5eb4 100644 --- a/arch/mips/lasat/interrupt.c +++ b/arch/mips/lasat/interrupt.c | |||
@@ -36,33 +36,14 @@ static volatile int lasat_int_mask_shift; | |||
36 | 36 | ||
37 | void disable_lasat_irq(unsigned int irq_nr) | 37 | void disable_lasat_irq(unsigned int irq_nr) |
38 | { | 38 | { |
39 | unsigned long flags; | ||
40 | |||
41 | local_irq_save(flags); | ||
42 | *lasat_int_mask &= ~(1 << irq_nr) << lasat_int_mask_shift; | 39 | *lasat_int_mask &= ~(1 << irq_nr) << lasat_int_mask_shift; |
43 | local_irq_restore(flags); | ||
44 | } | 40 | } |
45 | 41 | ||
46 | void enable_lasat_irq(unsigned int irq_nr) | 42 | void enable_lasat_irq(unsigned int irq_nr) |
47 | { | 43 | { |
48 | unsigned long flags; | ||
49 | |||
50 | local_irq_save(flags); | ||
51 | *lasat_int_mask |= (1 << irq_nr) << lasat_int_mask_shift; | 44 | *lasat_int_mask |= (1 << irq_nr) << lasat_int_mask_shift; |
52 | local_irq_restore(flags); | ||
53 | } | 45 | } |
54 | 46 | ||
55 | static unsigned int startup_lasat_irq(unsigned int irq) | ||
56 | { | ||
57 | enable_lasat_irq(irq); | ||
58 | |||
59 | return 0; /* never anything pending */ | ||
60 | } | ||
61 | |||
62 | #define shutdown_lasat_irq disable_lasat_irq | ||
63 | |||
64 | #define mask_and_ack_lasat_irq disable_lasat_irq | ||
65 | |||
66 | static void end_lasat_irq(unsigned int irq) | 47 | static void end_lasat_irq(unsigned int irq) |
67 | { | 48 | { |
68 | if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS))) | 49 | if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS))) |
@@ -71,11 +52,10 @@ static void end_lasat_irq(unsigned int irq) | |||
71 | 52 | ||
72 | static struct irq_chip lasat_irq_type = { | 53 | static struct irq_chip lasat_irq_type = { |
73 | .typename = "Lasat", | 54 | .typename = "Lasat", |
74 | .startup = startup_lasat_irq, | 55 | .ack = disable_lasat_irq, |
75 | .shutdown = shutdown_lasat_irq, | 56 | .mask = disable_lasat_irq, |
76 | .enable = enable_lasat_irq, | 57 | .mask_ack = disable_lasat_irq, |
77 | .disable = disable_lasat_irq, | 58 | .unmask = enable_lasat_irq, |
78 | .ack = mask_and_ack_lasat_irq, | ||
79 | .end = end_lasat_irq, | 59 | .end = end_lasat_irq, |
80 | }; | 60 | }; |
81 | 61 | ||
@@ -152,10 +132,6 @@ void __init arch_init_irq(void) | |||
152 | panic("arch_init_irq: mips_machtype incorrect"); | 132 | panic("arch_init_irq: mips_machtype incorrect"); |
153 | } | 133 | } |
154 | 134 | ||
155 | for (i = 0; i <= LASATINT_END; i++) { | 135 | for (i = 0; i <= LASATINT_END; i++) |
156 | irq_desc[i].status = IRQ_DISABLED; | 136 | set_irq_chip(i, &lasat_irq_type); |
157 | irq_desc[i].action = 0; | ||
158 | irq_desc[i].depth = 1; | ||
159 | irq_desc[i].chip = &lasat_irq_type; | ||
160 | } | ||
161 | } | 137 | } |