adrsvc ne, lr, 1b
@
@ routine called with r0 = irq number, r1 = struct pt_regs *
@
bne do_IRQ @ 調(diào)用do_IRQ來實現(xiàn)具體的中斷處理
mov why, #0
get_current_task tsk
b ret_to_user
對于以上代碼,在很多文章中都有過分析,這里不再贅述。
Linux每個中斷通過一個結(jié)構(gòu)irqdesc來描述,各中斷的信息都在這個結(jié)構(gòu)中得以體現(xiàn):
struct irqdesc {
unsigned int nomask : 1; /* IRQ does not mask in IRQ */
unsigned int enabled : 1; /* IRQ is currently enabled */
unsigned int triggered: 1; /* IRQ has occurred */
unsigned int probing : 1; /* IRQ in use for a probe */
unsigned int probe_ok : 1; /* IRQ can be used for probe */
unsigned int valid : 1; /* IRQ claimable */
unsigned int noautoenable : 1; /* don't automatically enable IRQ */
unsigned int unused :25;
void (*mask_ack)(unsigned int irq); /* Mask and acknowledge IRQ */
void (*mask)(unsigned int irq); /* Mask IRQ */
void (*unmask)(unsigned int irq);  





