diff options
Diffstat (limited to 'arch/arm')
| -rw-r--r-- | arch/arm/include/asm/mach/irq.h | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/arch/arm/include/asm/mach/irq.h b/arch/arm/include/asm/mach/irq.h index 22ac140edd9e..febe495d0c6e 100644 --- a/arch/arm/include/asm/mach/irq.h +++ b/arch/arm/include/asm/mach/irq.h | |||
| @@ -34,4 +34,35 @@ do { \ | |||
| 34 | raw_spin_unlock(&desc->lock); \ | 34 | raw_spin_unlock(&desc->lock); \ |
| 35 | } while(0) | 35 | } while(0) |
| 36 | 36 | ||
| 37 | #ifndef __ASSEMBLY__ | ||
| 38 | /* | ||
| 39 | * Entry/exit functions for chained handlers where the primary IRQ chip | ||
| 40 | * may implement either fasteoi or level-trigger flow control. | ||
| 41 | */ | ||
| 42 | static inline void chained_irq_enter(struct irq_chip *chip, | ||
| 43 | struct irq_desc *desc) | ||
| 44 | { | ||
| 45 | /* FastEOI controllers require no action on entry. */ | ||
| 46 | if (chip->irq_eoi) | ||
| 47 | return; | ||
| 48 | |||
| 49 | if (chip->irq_mask_ack) { | ||
| 50 | chip->irq_mask_ack(&desc->irq_data); | ||
| 51 | } else { | ||
| 52 | chip->irq_mask(&desc->irq_data); | ||
| 53 | if (chip->irq_ack) | ||
| 54 | chip->irq_ack(&desc->irq_data); | ||
| 55 | } | ||
| 56 | } | ||
| 57 | |||
| 58 | static inline void chained_irq_exit(struct irq_chip *chip, | ||
| 59 | struct irq_desc *desc) | ||
| 60 | { | ||
| 61 | if (chip->irq_eoi) | ||
| 62 | chip->irq_eoi(&desc->irq_data); | ||
| 63 | else | ||
| 64 | chip->irq_unmask(&desc->irq_data); | ||
| 65 | } | ||
| 66 | #endif | ||
| 67 | |||
| 37 | #endif | 68 | #endif |
