diff options
author | Yinghai Lu <yhlu.kernel@gmail.com> | 2008-08-19 23:50:15 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-10-16 10:52:50 -0400 |
commit | 46926b67fc663d357a1a8174328998a9e49da0b8 (patch) | |
tree | 33870a6c416bbc4d246ecfbf015a78c61943a36d /include/linux/irq.h | |
parent | 7d94f7ca401dd7f445fda9a971a48aa5427b3e55 (diff) |
generic: add irq_desc in function in parameter
So we could remove some duplicated calling to irq_desc
v2: make sure irq_desc in init/main.c is not used without generic_hardirqs
Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/irq.h')
-rw-r--r-- | include/linux/irq.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/include/linux/irq.h b/include/linux/irq.h index 9de16ca8b8e5..7b59e193a119 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -315,10 +315,8 @@ extern unsigned int __do_IRQ(unsigned int irq); | |||
315 | * irqchip-style controller then we call the ->handle_irq() handler, | 315 | * irqchip-style controller then we call the ->handle_irq() handler, |
316 | * and it calls __do_IRQ() if it's attached to an irqtype-style controller. | 316 | * and it calls __do_IRQ() if it's attached to an irqtype-style controller. |
317 | */ | 317 | */ |
318 | static inline void generic_handle_irq(unsigned int irq) | 318 | static inline void generic_handle_irq_desc(unsigned int irq, struct irq_desc *desc) |
319 | { | 319 | { |
320 | struct irq_desc *desc = irq_to_desc(irq); | ||
321 | |||
322 | #ifdef CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ | 320 | #ifdef CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ |
323 | desc->handle_irq(irq, desc); | 321 | desc->handle_irq(irq, desc); |
324 | #else | 322 | #else |
@@ -329,6 +327,11 @@ static inline void generic_handle_irq(unsigned int irq) | |||
329 | #endif | 327 | #endif |
330 | } | 328 | } |
331 | 329 | ||
330 | static inline void generic_handle_irq(unsigned int irq) | ||
331 | { | ||
332 | generic_handle_irq_desc(irq, irq_to_desc(irq)); | ||
333 | } | ||
334 | |||
332 | /* Handling of unhandled and spurious interrupts: */ | 335 | /* Handling of unhandled and spurious interrupts: */ |
333 | extern void note_interrupt(unsigned int irq, struct irq_desc *desc, | 336 | extern void note_interrupt(unsigned int irq, struct irq_desc *desc, |
334 | int action_ret); | 337 | int action_ret); |