// wdfinterrupt.h
WDFDEVICE WdfInterruptGetDevice(
[in] WDFINTERRUPT Interrupt
);
View the official Windows Driver Kit DDI referenceNo description available.
[Applies to KMDF and UMDF]
The WdfInterruptGetDevice method returns a handle to the framework device object that is associated with a specified framework interrupt object.
Interrupt [in]A handle to a framework interrupt object.
WdfInterruptGetDevice returns a handle to a framework device object.
A bug check occurs if the driver supplies an invalid object handle.
For more information about handling interrupts in framework-based drivers, see Handling Hardware Interrupts.
The following code example shows how an EvtInterruptIsr callback function can obtain a pointer to driver-defined context space for the device object that an interrupt object belongs to.
BOOLEAN
MyEvtInterruptIsr(
IN WDFINTERRUPT Interrupt,
IN ULONG MessageID
)
{
PDEVICE_EXTENSION devExt;
devExt = GetMyDeviceContext(WdfInterruptGetDevice(Interrupt));
...
}