From dd87eb3a24c4527741122713e223d74b85d43c85 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Thu, 29 Jun 2006 02:24:53 -0700 Subject: [PATCH] genirq: add irq-chip support Enable platforms to use the irq-chip and irq-flow abstractions: allow setting of the chip, the type and provide highlevel handlers for common irq-flows. [rostedt@goodmis.org: misroute-irq: Don't call desc->chip->end because of edge interrupts] Signed-off-by: Thomas Gleixner Signed-off-by: Ingo Molnar Cc: Benjamin Herrenschmidt Signed-off-by: Steven Rostedt Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/irq.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include') diff --git a/include/linux/irq.h b/include/linux/irq.h index b40771dd114..ca8d2a849cf 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h @@ -383,6 +383,17 @@ set_irq_chained_handler(unsigned int irq, __set_irq_handler(irq, handle, 1); } +/* Set/get chip/data for an IRQ: */ + +extern int set_irq_chip(unsigned int irq, struct irq_chip *chip); +extern int set_irq_data(unsigned int irq, void *data); +extern int set_irq_chip_data(unsigned int irq, void *data); +extern int set_irq_type(unsigned int irq, unsigned int type); + +#define get_irq_chip(irq) (irq_desc[irq].chip) +#define get_irq_chip_data(irq) (irq_desc[irq].chip_data) +#define get_irq_data(irq) (irq_desc[irq].handler_data) + #endif /* CONFIG_GENERIC_HARDIRQS */ #endif /* !CONFIG_S390 */ -- cgit v1.2.3