DXGKDDI_INTERRUPT_ROUTINE callback function

The DxgkDdiInterruptRoutine function handles interrupts generated by a display adapter.

Syntax

DXGKDDI_INTERRUPT_ROUTINE DxgkddiInterruptRoutine;

BOOLEAN DxgkddiInterruptRoutine(
  IN_CONST_PVOID MiniportDeviceContext,
  IN_ULONG MessageNumber
)
{...}

Parameters

MiniportDeviceContext

A handle to a context block associated with a display adapter. The display miniport driver's DxgkDdiAddDevice function previously provided this handle to the DirectX graphics kernel subsystem.

MessageNumber

The message number if the interrupt is message-signaled. For line-based interrupts, this parameter is zero.

Return Value

If DxgkDdiInterruptRoutine determines that the adapter represented by MiniportDeviceContext did not generate the interrupt, it returns FALSE. Otherwise, it must dismiss the interrupt on the adapter before it returns TRUE.

Remarks

If the interrupt is line-based (MessageNumber = 0), DxgkDdiInterruptRoutine must determine whether the adapter represented by MiniportDeviceContext generated the interrupt and, if not, return FALSE immediately.

If the adapter represented by MiniportDeviceContext did generate the interrupt, then DxgkDdiInterruptRoutine should perform the following steps:

  • Dismiss the interrupt on the adapter.

  • Complete the requested operation that caused the interrupt, or queue a DPC that will complete the operation later.

  • Return TRUE as quickly as possible.

Any other display miniport driver function that shares memory (for example, some portion of the state represented by MiniportDeviceContext) with DxgkDdiInterruptRoutine must call DxgkCbSynchronizeExecution to synchronize its access to the shared memory.

The DxgkDdiInterruptRoutine function can call DxgkCbQueueDpc and DxgkCbNotifyInterrupt but must not call any other DxgkCbXxx functions. For more information on the proper sequence of function calls, see Submitting a Command Buffer.

DxgkDdiInterruptRoutine runs at an elevated IRQL, so it (and all the functions it calls) must be non-pageable. Also, DxgkDdiInterruptRoutine (and all the functions it calls) must not attempt to access pageable memory.

Requirements

   
Windows version Available in Windows Vista and later versions of the Windows operating systems.
Target Platform Desktop
Header dispmprt.h
IRQL See Remarks section.

See Also

DxgkCbNotifyInterrupt

DxgkCbQueueDpc

DxgkCbSynchronizeExecution