DDI_INTR_HILEVEL(9F) | Kernel Functions for Drivers | DDI_INTR_HILEVEL(9F) |
#include <sys/ddi.h> #include <sys/sunddi.h> int ddi_intr_hilevel(dev_info_t *dip, uint_t inumber);
inumber
High level interrupts must be handled without using system services that manipulate thread or process states, because these interrupts are not blocked by the scheduler.
In addition, high level interrupt handlers must take care to do a minimum of work because they are not preemptable.
A typical high level interrupt handler would put data into a circular buffer and schedule a soft interrupt by calling ddi_trigger_softintr(). The circular buffer could be protected by using a mutex that was properly initialized for the interrupt handler.
The ddi_intr_hilevel() function can be used before calling ddi_add_intr() to decide which type of interrupt handler should be used. Most device drivers are designed with the knowledge that the devices they support will always generate low level interrupts, however some devices, for example those using SBus or VME bus level 6 or 7 interrupts must use this test because on some machines those interrupts are high level (above the scheduler level) and on other machines they are not.
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
Interface Stability | Obsolete |
Writing Device Drivers
January 16, 2006 | OmniOS |