DCMD_PROC_IRQS

Finally, we can also find out about the interrupts that are associated with a process.

We use the
DCMD_PROC_IRQS
command, and expect to get back zero or more data structures,
as we did in the DCMD_PROC_PAGEDATA, DCMD_PROC_MAPINFO,
and DCMD_PROC_TIMERS examples above.
The structure procfs_irq is the same as the debug_irq_t, which is defined as follows:

The pid and tid fields give the process ID and the thread ID
(process ID 8200 in this example is devb-eide).

handler and area

Indicates the interrupt service routine address, and its associated parameter.
The fact that the interrupt handler address is zero indicates that there is no real interrupt vector
associated with the interrupts; rather, the event (a pulse in both cases) should be
returned (i.e., the interrupt was attached with InterruptAttachEvent() rather than
InterruptAttach()).
In the case of the handler being zero, the area member is not important.

flags

The flags value is hexadecimal 0x0C, which is composed of the bits
_NTO_INTR_FLAGS_PROCESS
and _NTO_INTR_FLAGS_TRK_MSK,
meaning, respectively, that
the interrupt belongs to the process (rather than the
thread), and the kernel should keep track of the number of times that the interrupt is masked and unmasked.

latency

The latency value, in nanoseconds, that the kernel uses in calculations for lazy interrupts.
You can use
InterruptCharacteristic()
to set this latency.

mask_count

Indicates the number of times the interrupt is masked (0 indicates the interrupt is not masked).
Useful as a diagnostic aid when you are trying to determine why your interrupt fires only once. :-)

id

This is the interrupt identification number returned by InterruptAttach() or
InterruptAttachEvent().

vector

This is the interrupt vector for this particular interrupt.
In our example, devb-eide is attached to two interrupt sources (as defined by the
vector parameter; i.e., interrupts 14 and 15, the two EIDE controllers on my PC).

handler and area

Indicates the interrupt service routine address, and its associated parameter.
The fact that the interrupt handler address is zero indicates that there is no real interrupt vector
associated with the interrupts; rather, the event (a pulse in both cases) should be
returned (i.e., the interrupt was attached with InterruptAttachEvent() rather than
InterruptAttach()).
In the case of the handler being zero, the area member is not important.

event

A standard struct sigevent that determines what the InterruptAttachEvent()
should do when it fires.