4 * Encapsulation of the platforms interrupt controller
10 * The type holding the saved Pic state.
12 typedef unsigned Status;
15 * Static initalization of the interrupt controller
20 * Disable the given irq (without lock protection).
21 * @pre The Cpu_lock must be locked (cli'ed)
23 * This function must be implemented in the
24 * architecture specific part (e.g. pic-i8259.cpp).
26 static void disable_locked( unsigned irqnum );
29 * Enable the given irq (without lock protection).
30 * @pre The Cpu_lock must be locked (cli'ed)
32 * This function must be implemented in the
33 * architecture specific part (e.g. pic-i8259.cpp).
35 static void enable_locked(unsigned irqnum, unsigned prio = 0);
38 * Temporarily block the IRQ til the next ACK.
39 * @pre The Cpu_lock must be locked (cli'ed)
41 * This function must be implemented in the
42 * architecture specific part (e.g. pic-i8259.cpp).
44 static void block_locked(unsigned irqnum);
47 * Disable all IRQ's and and return the old Pic state.
48 * @pre Must be done with disabled interrupts.
50 static Status disable_all_save();
53 * Restore the IRQ's to the saved state s.
54 * @pre Must be done with disabled interrupts.
55 * @param s, the saved state.
57 static void restore_all( Status s );
60 * Acknowledge the given IRQ.
61 * @pre The Cpu_lock must be locked (cli'ed).
62 * @param irq, the irq to acknowledge.
64 * This function must be implemented in the
65 * architecture specific part (e.g. pic-i8259.cpp).
67 static void acknowledge_locked( unsigned irq );
70 * Set CPU affinity of IRQ.
72 * @param cpu Logical CPU.
74 static void set_cpu(unsigned irq, unsigned cpu);