diff options
| -rw-r--r-- | include/linux/interrupt.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h index 2c5452c1d7bb..73463fbb38e4 100644 --- a/include/linux/interrupt.h +++ b/include/linux/interrupt.h | |||
| @@ -80,6 +80,23 @@ extern int request_irq(unsigned int, | |||
| 80 | unsigned long, const char *, void *); | 80 | unsigned long, const char *, void *); |
| 81 | extern void free_irq(unsigned int, void *); | 81 | extern void free_irq(unsigned int, void *); |
| 82 | 82 | ||
| 83 | /* | ||
| 84 | * On lockdep we dont want to enable hardirqs in hardirq | ||
| 85 | * context. Use local_irq_enable_in_hardirq() to annotate | ||
| 86 | * kernel code that has to do this nevertheless (pretty much | ||
| 87 | * the only valid case is for old/broken hardware that is | ||
| 88 | * insanely slow). | ||
| 89 | * | ||
| 90 | * NOTE: in theory this might break fragile code that relies | ||
| 91 | * on hardirq delivery - in practice we dont seem to have such | ||
| 92 | * places left. So the only effect should be slightly increased | ||
| 93 | * irqs-off latencies. | ||
| 94 | */ | ||
| 95 | #ifdef CONFIG_LOCKDEP | ||
| 96 | # define local_irq_enable_in_hardirq() do { } while (0) | ||
| 97 | #else | ||
| 98 | # define local_irq_enable_in_hardirq() local_irq_enable() | ||
| 99 | #endif | ||
| 83 | 100 | ||
| 84 | #ifdef CONFIG_GENERIC_HARDIRQS | 101 | #ifdef CONFIG_GENERIC_HARDIRQS |
| 85 | extern void disable_irq_nosync(unsigned int irq); | 102 | extern void disable_irq_nosync(unsigned int irq); |
