DXGKDDI_CANCELCOMMAND callback function (d3dkmddi.h)

Cleans up internal resources associated with a direct memory access (DMA) packet that was in the GPU scheduler's software queue but never reached the hardware queue because the device went into an error state. Such an error state is typically caused by a Timeout Detection and Recovery (TDR) event.

Syntax

DXGKDDI_CANCELCOMMAND DxgkddiCancelcommand;

NTSTATUS DxgkddiCancelcommand(
  IN_CONST_HANDLE hAdapter,
  IN_CONST_PDXGKARG_CANCELCOMMAND pCancelCommand
)
{...}

Parameters

hAdapter

A handle to a context block that is associated with a display adapter. The display miniport driver previously provided this handle to the DirectX graphics kernel subsystem in the MiniportDeviceContext output parameter of the DxgkDdiAddDevice function.

pCancelCommand

A pointer to a DXGKARG_CANCELCOMMAND structure that specifies resources to be cleaned up after a command is removed from the hardware queue.

Return value

Returns STATUS_SUCCESS upon successful completion. If the driver instead returns an error code, the operating system causes a system bugcheck to occur. For more information, see the following Remarks section.

Remarks

Note  The DirectX graphics kernel subsystem calls this function only if the DXGK_VIDSCHCAPS.CancelCommandAware member is set.
 
If the driver returns an error code, the DirectX graphics kernel subsystem causes a system bugcheck to occur. In a crash dump file, the error is noted by the message BugCheck 0x119, which has the following four parameters.
  1. 0x9
  2. The NTSTATUS error code returned from the failed driver call
  3. A pointer to the DXGKARG_CANCELCOMMAND structure
  4. A pointer to an internal scheduler data structure

Requirements

Requirement Value
Minimum supported client Windows 8
Minimum supported server Windows Server 2012
Target Platform Desktop
Header d3dkmddi.h
IRQL PASSIVE_LEVEL

See also

DXGKARG_CANCELCOMMAND

DXGK_VIDSCHCAPS

DxgkDdiAddDevice