aboutsummaryrefslogtreecommitdiffstats
path: root/arch/m68k/kernel/ints.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/m68k/kernel/ints.c')
-rw-r--r--arch/m68k/kernel/ints.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/arch/m68k/kernel/ints.c b/arch/m68k/kernel/ints.c
index e68a3bd5de6e..4f9868e160bd 100644
--- a/arch/m68k/kernel/ints.c
+++ b/arch/m68k/kernel/ints.c
@@ -55,6 +55,12 @@ static struct irq_data *irq_list[NR_IRQS];
55static struct irq_chip *irq_chip[NR_IRQS]; 55static struct irq_chip *irq_chip[NR_IRQS];
56static int irq_depth[NR_IRQS]; 56static int irq_depth[NR_IRQS];
57 57
58static inline int irq_set_chip(unsigned int irq, struct irq_chip *chip)
59{
60 irq_chip[irq] = chip;
61 return 0;
62}
63
58static int m68k_first_user_vec; 64static int m68k_first_user_vec;
59 65
60static struct irq_chip auto_irq_chip = { 66static struct irq_chip auto_irq_chip = {
@@ -94,7 +100,7 @@ void __init init_IRQ(void)
94 } 100 }
95 101
96 for (i = IRQ_AUTO_1; i <= IRQ_AUTO_7; i++) 102 for (i = IRQ_AUTO_1; i <= IRQ_AUTO_7; i++)
97 irq_chip[i] = &auto_irq_chip; 103 irq_set_chip(i, &auto_irq_chip);
98 104
99 mach_init_IRQ(); 105 mach_init_IRQ();
100} 106}
@@ -134,7 +140,7 @@ void __init m68k_setup_user_interrupt(unsigned int vec, unsigned int cnt,
134 BUG_ON(IRQ_USER + cnt > NR_IRQS); 140 BUG_ON(IRQ_USER + cnt > NR_IRQS);
135 m68k_first_user_vec = vec; 141 m68k_first_user_vec = vec;
136 for (i = 0; i < cnt; i++) 142 for (i = 0; i < cnt; i++)
137 irq_chip[IRQ_USER + i] = &user_irq_chip; 143 irq_set_chip(IRQ_USER + i, &user_irq_chip);
138 *user_irqvec_fixup = vec - IRQ_USER; 144 *user_irqvec_fixup = vec - IRQ_USER;
139 if (handler) 145 if (handler)
140 *user_irqhandler_fixup = (u32)handler; 146 *user_irqhandler_fixup = (u32)handler;
@@ -157,7 +163,7 @@ void m68k_setup_irq_chip(struct irq_chip *contr, unsigned int irq,
157 int i; 163 int i;
158 164
159 for (i = 0; i < cnt; i++) 165 for (i = 0; i < cnt; i++)
160 irq_chip[irq + i] = contr; 166 irq_set_chip(irq + i, contr);
161} 167}
162 168
163struct irq_data *new_irq_node(void) 169struct irq_data *new_irq_node(void)