c - Explanation of __do_IRQ function -
i'm preparing presentation on how linux kernel handles interrupts based on book understanding linux kernel ny bovet & cesati. cover says covers version 2.6. however, can't quite figure out how given __do_irq() function supposed work. although i've done (basic) c programming, can't understand of instructions. spin_lock(&(irq_desc[irq].lock)); irq_desc[irq].handler->ack(irq); irq_desc[irq].status &= ~(irq_replay | irq_waiting); irq_desc[irq].status |= irq_pending; if (!(irq_desc[irq].status & (irq_disabled | irq_inprogress)) && irq_desc[irq].action){ irq_desc[irq].status |= irq_inprogress; do{ irq_desc[irq].status &= ~irq_pending; spin_unlock(&(irq_desc[irq].lock)); handle_irq_event(irq,regs,irq_desc[irq].action); spin_lock(&(irq_desc[irq].lock)); }while (irq_desc[irq].status & irq_pending); irq_desc[irq].status &= ~irq_inprogress; } irq_desc[irq].handler->end(irq)