Bewerken

Delen via


WdfInterruptGetInfo function (wdfinterrupt.h)

[Applies to KMDF and UMDF]

The WdfInterruptGetInfo method retrieves information about a specified interrupt.

Syntax

void WdfInterruptGetInfo(
  [in]      WDFINTERRUPT        Interrupt,
  [in, out] PWDF_INTERRUPT_INFO Info
);

Parameters

[in] Interrupt

A handle to the interrupt object.

[in, out] Info

A pointer to a caller-allocated WDF_INTERRUPT_INFO structure that has been initialized by calling WDF_INTERRUPT_INFO_INIT.

Return value

None

Remarks

A bug check occurs if the driver supplies an invalid object handle.

The WdfInterruptGetInfo method can obtain interrupt information only if your driver calls it after the framework has called the driver's EvtDevicePrepareHardware callback function and before the framework has called the driver's EvtDeviceReleaseHardware callback function.

After WdfInterruptGetInfo has returned, the driver can identify passive level interrupt objects by examining the Irql member of the WDF_INTERRUPT_INFO structure. For passive level interrupt objects, this value is PASSIVE_LEVEL.

For information about the order in which a driver's callback functions are called, see PnP and Power Management Scenarios.

For more information about handling interrupts in framework-based drivers, see Handling Hardware Interrupts.

Examples

The following code example initializes a WDF_INTERRUPT_INFO structure and calls WdfInterruptGetInfo.

WDF_INTERRUPT_INFO  Info;

WDF_INTERRUPT_INFO_INIT(&Info);
WdfInterruptGetInfo(
                    Interrupt,
                    &Info
                    );

Requirements

Requirement Value
Target Platform Universal
Minimum KMDF version 1.0
Minimum UMDF version 2.0
Header wdfinterrupt.h (include Wdf.h)
Library Wdf01000.sys (KMDF); WUDFx02000.dll (UMDF)
IRQL <=DISPATCH_LEVEL
DDI compliance rules DriverCreate(kmdf)

See also

EvtDevicePrepareHardware

EvtDeviceReleaseHardware

WDF_INTERRUPT_INFO

WDF_INTERRUPT_INFO_INIT