//This is the magic sauce which forces a message back to the registered proc process* irq_handle(unsigned char irq_number) { DEBUG("\nIRQ "); DEBUG_HD(irq_number); DEBUG(" triggered\n"); irq_number -= 0xE0; //Get the heck out of here if the irq isn't registered if(!irq_process[irq_number - 1]) { DEBUG("Nothing registered for this IRQ"); return (process*)0; } //Otherwise, write a message to the handling process and enter it passMessage(0, irq_process[irq_number - 1]->id, KS_REG_IRQ_1 + irq_number - 1, 0); //Tell the PIC we're ready to accept further interrupts on this channel send_pic_eoi(irq_number); return irq_process[irq_number - 1]; }
void timer_int_ack() { send_pic_eoi(0); }