Bewerken

Delen via


DXGKDDI_DESTROYCPUEVENT callback function (d3dkmddi.h)

DXGKDDI_DESTROYCPUEVENT destroys the specified kernel-mode driver (KMD) CPU object.

Syntax

DXGKDDI_DESTROYCPUEVENT DxgkddiDestroycpuevent;

NTSTATUS DxgkddiDestroycpuevent(
  IN_CONST_HANDLE hAdapter,
  IN_CONST_HANDLE hKmdCpuEvent
)
{...}

Parameters

hAdapter

[in] Handle to a KMD context that is associated with a display adapter. The display miniport driver previously provided this handle to Dxgkrnl in the MiniportDeviceContext output parameter of the DXGKDDI_ADD_DEVICE function.

hKmdCpuEvent

[in] KMD CPU event object handle, which was returned by KMD from DXGKDDI_CREATECPUEVENT.

Return value

DXGKDDI_DESTROYCPUEVENT returns STATUS_SUCCESS if it succeeds; otherwise, it returns one of the error codes defined in Ntstatus.h.

Remarks

The Dxgkrnl CPU event object cannot be used after this DDI is called. The driver must synchronize destruction with all calls to DXGKCB_SIGNALEVENT.

It is guaranteed that the OS will call this DDI to destroy KMD sync objects. Objects could be destroyed when a user-mode client destroys a sync object, when a process terminates, or when the adapter is stopped.

See Signaling a CPU event from KMD for more information.

Requirements

Requirement Value
Minimum supported client Windows 11 version 21H2 (WDDM 3.0)
Header d3dkmddi.h
IRQL PASSIVE_LEVEL

See also

DXGKDDI_CREATECPUEVENT