diff options
Diffstat (limited to 'include/linux/irq.h')
-rw-r--r-- | include/linux/irq.h | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/include/linux/irq.h b/include/linux/irq.h index 5f695041090c..59517300a315 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -23,6 +23,7 @@ | |||
23 | #include <linux/errno.h> | 23 | #include <linux/errno.h> |
24 | #include <linux/topology.h> | 24 | #include <linux/topology.h> |
25 | #include <linux/wait.h> | 25 | #include <linux/wait.h> |
26 | #include <linux/module.h> | ||
26 | 27 | ||
27 | #include <asm/irq.h> | 28 | #include <asm/irq.h> |
28 | #include <asm/ptrace.h> | 29 | #include <asm/ptrace.h> |
@@ -108,14 +109,18 @@ enum { | |||
108 | }; | 109 | }; |
109 | 110 | ||
110 | struct msi_desc; | 111 | struct msi_desc; |
112 | struct irq_domain; | ||
111 | 113 | ||
112 | /** | 114 | /** |
113 | * struct irq_data - per irq and irq chip data passed down to chip functions | 115 | * struct irq_data - per irq and irq chip data passed down to chip functions |
114 | * @irq: interrupt number | 116 | * @irq: interrupt number |
117 | * @hwirq: hardware interrupt number, local to the interrupt domain | ||
115 | * @node: node index useful for balancing | 118 | * @node: node index useful for balancing |
116 | * @state_use_accessors: status information for irq chip functions. | 119 | * @state_use_accessors: status information for irq chip functions. |
117 | * Use accessor functions to deal with it | 120 | * Use accessor functions to deal with it |
118 | * @chip: low level interrupt hardware access | 121 | * @chip: low level interrupt hardware access |
122 | * @domain: Interrupt translation domain; responsible for mapping | ||
123 | * between hwirq number and linux irq number. | ||
119 | * @handler_data: per-IRQ data for the irq_chip methods | 124 | * @handler_data: per-IRQ data for the irq_chip methods |
120 | * @chip_data: platform-specific per-chip private data for the chip | 125 | * @chip_data: platform-specific per-chip private data for the chip |
121 | * methods, to allow shared chip implementations | 126 | * methods, to allow shared chip implementations |
@@ -128,9 +133,11 @@ struct msi_desc; | |||
128 | */ | 133 | */ |
129 | struct irq_data { | 134 | struct irq_data { |
130 | unsigned int irq; | 135 | unsigned int irq; |
136 | unsigned long hwirq; | ||
131 | unsigned int node; | 137 | unsigned int node; |
132 | unsigned int state_use_accessors; | 138 | unsigned int state_use_accessors; |
133 | struct irq_chip *chip; | 139 | struct irq_chip *chip; |
140 | struct irq_domain *domain; | ||
134 | void *handler_data; | 141 | void *handler_data; |
135 | void *chip_data; | 142 | void *chip_data; |
136 | struct msi_desc *msi_desc; | 143 | struct msi_desc *msi_desc; |
@@ -541,7 +548,15 @@ static inline struct msi_desc *irq_data_get_msi(struct irq_data *d) | |||
541 | return d->msi_desc; | 548 | return d->msi_desc; |
542 | } | 549 | } |
543 | 550 | ||
544 | int irq_alloc_descs(int irq, unsigned int from, unsigned int cnt, int node); | 551 | int __irq_alloc_descs(int irq, unsigned int from, unsigned int cnt, int node, |
552 | struct module *owner); | ||
553 | |||
554 | static inline int irq_alloc_descs(int irq, unsigned int from, unsigned int cnt, | ||
555 | int node) | ||
556 | { | ||
557 | return __irq_alloc_descs(irq, from, cnt, node, THIS_MODULE); | ||
558 | } | ||
559 | |||
545 | void irq_free_descs(unsigned int irq, unsigned int cnt); | 560 | void irq_free_descs(unsigned int irq, unsigned int cnt); |
546 | int irq_reserve_irqs(unsigned int from, unsigned int cnt); | 561 | int irq_reserve_irqs(unsigned int from, unsigned int cnt); |
547 | 562 | ||