Home | History | Annotate | Download | only in linux

Lines Matching full:irq

22 #include <asm/irq.h>
26 * IRQ line status.
30 * IRQ types
42 #define IRQ_INPROGRESS 0x00010000 /* IRQ handler active - do not enter! */
43 #define IRQ_DISABLED 0x00020000 /* IRQ disabled - do not enter! */
44 #define IRQ_PENDING 0x00040000 /* IRQ pending - replay on enable */
45 #define IRQ_REPLAY 0x00080000 /* IRQ has been replayed but not acked yet */
46 #define IRQ_AUTODETECT 0x00100000 /* IRQ is being autodetected */
47 #define IRQ_WAITING 0x00200000 /* IRQ not yet seen - for autodetection */
48 #define IRQ_LEVEL 0x00400000 /* IRQ level triggered */
49 #define IRQ_MASKED 0x00800000 /* IRQ masked - shouldn't be seen again */
50 #define IRQ_PER_CPU 0x01000000 /* IRQ is per CPU */
57 #define IRQ_NOPROBE 0x02000000 /* IRQ is not valid for probing */
58 #define IRQ_NOREQUEST 0x04000000 /* IRQ cannot be requested */
59 #define IRQ_NOAUTOEN 0x08000000 /* IRQ will not be enabled on request irq */
60 #define IRQ_DELAYED_DISABLE 0x10000000 /* IRQ disable (masking) happens delayed. */
61 #define IRQ_WAKEUP 0x20000000 /* IRQ triggers system wakeup */
80 * @retrigger: resend an IRQ to the CPU
81 * @set_type: set the flow type (IRQ_TYPE_LEVEL/etc.) of an IRQ
82 * @set_wake: enable/disable power-management wake-on of an IRQ
89 unsigned int (*startup)(unsigned int irq);
90 void (*shutdown)(unsigned int irq);
91 void (*enable)(unsigned int irq);
92 void (*disable)(unsigned int irq);
94 void (*ack)(unsigned int irq);
95 void (*mask)(unsigned int irq);
96 void (*mask_ack)(unsigned int irq);
97 void (*unmask)(unsigned int irq);
98 void (*eoi)(unsigned int irq);
100 void (*end)(unsigned int irq);
101 void (*set_affinity)(unsigned int irq, cpumask_t dest);
102 int (*retrigger)(unsigned int irq);
103 int (*set_type)(unsigned int irq, unsigned int flow_type);
104 int (*set_wake)(unsigned int irq, unsigned int on);
108 void (*release)(unsigned int irq, void *dev_id);
120 * @handle_irq: highlevel irq-events handler [if NULL, __do_IRQ()]
122 * @handler_data: per-IRQ data for the irq_chip methods
125 * @action: the irq action chain
132 * @affinity: IRQ affinity on SMP
135 * @move_irq: need to re-target IRQ destination
136 * @dir: /proc/irq/ procfs entry
137 * @affinity_entry: /proc/irq/smp_affinity procfs entry on SMP
142 void fastcall (*handle_irq)(unsigned int irq,
148 struct irqaction *action; /* IRQ action list */
149 unsigned int status; /* IRQ status */
151 unsigned int depth; /* nested irq disables */
162 unsigned int move_irq; /* need to re-target IRQ dest */
184 extern int setup_irq(unsigned int irq, struct irqaction *new);
193 static inline void set_native_irq_info(int irq, cpumask_t mask)
195 irq_desc[irq].affinity = mask;
198 static inline void set_native_irq_info(int irq, cpumask_t mask)
207 void set_pending_irq(unsigned int irq, cpumask_t mask);
208 void move_native_irq(int irq);
214 * counter part after translating the vector to irq info. We need to perform
215 * this operation on the real irq, when we dont use vector, i.e when
218 static inline void move_irq(int irq)
222 static inline void set_irq_info(int irq, cpumask_t mask)
228 static inline void move_irq(int irq)
230 move_native_irq(irq);
233 static inline void set_irq_info(int irq, cpumask_t mask)
235 set_native_irq_info(irq, mask);
242 static inline void move_irq(int irq)
246 static inline void move_native_irq(int irq)
250 static inline void set_pending_irq(unsigned int irq, cpumask_t mask)
254 static inline void set_irq_info(int irq, cpumask_t mask)
256 set_native_irq_info(irq, mask);
269 extern void set_balance_irq_affinity(unsigned int irq, cpumask_t mask);
271 static inline void set_balance_irq_affinity(unsigned int irq, cpumask_t mask)
277 extern int select_smp_affinity(unsigned int irq);
279 static inline int select_smp_affinity(unsigned int irq)
287 /* Handle irq action chains: */
288 extern int handle_IRQ_event(unsigned int irq, struct pt_regs *regs,
292 * Built-in IRQ handlers for various IRQ types,
296 handle_level_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs);
298 handle_fasteoi_irq(unsigned int irq, struct irq_desc *desc,
301 handle_edge_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs);
303 handle_simple_irq(unsigned int irq, struct irq_desc *desc,
306 handle_percpu_irq(unsigned int irq, struct irq_desc *desc,
309 handle_bad_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs);
323 extern fastcall unsigned int __do_IRQ(unsigned int irq, struct pt_regs *regs);
326 * Architectures call this to let the generic IRQ layer
331 static inline void generic_handle_irq(unsigned int irq, struct pt_regs *regs)
333 struct irq_desc *desc = irq_desc + irq;
336 desc->handle_irq(irq, desc, regs);
338 __do_IRQ(irq, regs);
342 extern void note_interrupt(unsigned int irq, struct irq_desc *desc,
346 void check_irq_resend(struct irq_desc *desc, unsigned int irq);
348 /* Initialize /proc/irq/ */
351 /* Enable/disable irq debugging output: */
355 extern int can_request_irq(unsigned int irq, unsigned long irqflags);
357 /* Dummy irq-chip implementations: */
362 set_irq_chip_and_handler(unsigned int irq, struct irq_chip *chip,
367 __set_irq_handler(unsigned int irq,
373 * Set a highlevel flow handler for a given IRQ:
376 set_irq_handler(unsigned int irq,
380 __set_irq_handler(irq, handle, 0);
384 * Set a highlevel chained flow handler for a given IRQ.
389 set_irq_chained_handler(unsigned int irq,
393 __set_irq_handler(irq, handle, 1);
396 /* Set/get chip/data for an IRQ: */
398 extern int set_irq_chip(unsigned int irq, struct irq_chip *chip);
399 extern int set_irq_data(unsigned int irq, void *data);
400 extern int set_irq_chip_data(unsigned int irq, void *data);
401 extern int set_irq_type(unsigned int irq, unsigned int type);
403 #define get_irq_chip(irq) (irq_desc[irq].chip)
404 #define get_irq_chip_data(irq) (irq_desc[irq].chip_data)
405 #define get_irq_data(irq) (irq_desc[irq].handler_data)