kernel 里面的中断代码分析
kernel 里面的中断代码分析
kernel 里面的中断代码分析
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
* struct irq_desc - interrupt descriptor<br />
*<br />
* @handle_irq: highlevel irq-events handler [if NULL, __do_IRQ()]<br />
* @chip: low level interrupt hardware access<br />
* @handler_data: per-IRQ data for the irq_chip methods<br />
* @chip_data: platform-specific per-chip private data for the chip<br />
* methods, to allow shared chip implementations<br />
* @action: the irq action chain<br />
* @status: status information<br />
* @depth: disable-depth, for nested irq_disable() calls<br />
* @wake_depth: enable depth, for multiple set_irq_wake() callers<br />
* @irq_count: stats field to detect stalled irqs<br />
* @irqs_unhandled: stats field for spurious unhandled interrupts<br />
* @lock: locking for SMP<br />
* @affinity: IRQ affinity on SMP<br />
* @cpu: cpu index useful for balancing<br />
* @pending_mask: pending rebalanced interrupts<br />
* @move_irq: need to re-target IRQ destination<br />
* @dir: /proc/irq/ procfs entry<br />
* @affinity_entry: /proc/irq/smp_affinity procfs entry on SMP<br />
*<br />
* Pad this out to 32 bytes for cache and indexing reasons.<br />
*/<br />
struct irq_desc {<br />
void fastcall (*handle_irq)(unsigned int irq,<br />
struct irq_chip *chip;<br />
void *handler_data;<br />
void *chip_data;<br />
struct irq_desc *desc,<br />
struct pt_regs *regs);<br />
struct irqaction *action; /* IRQ action list */<br />
unsigned int status; /* IRQ status */<br />
unsigned int depth; /* nested irq disables */<br />
unsigned int wake_depth; /* nested wake enables */<br />
unsigned int irq_count; /* For detecting broken IRQs */<br />
unsigned int irqs_unhandled;<br />
spinlock_t lock;<br />
#ifdef CONFIG_SMP<br />
#endif<br />
cpumask_t affinity;<br />
unsigned int cpu;<br />
#if defined(CONFIG_GENERIC_PENDING_IRQ) || defined(CONFIG_IRQBALANCE)<br />
cpumask_t pending_mask;