DXGKCB_SAVEMEMORYFORHOTUPDATE callback function

Implemented by the client driver to save adapter memory to support driver hot update.

Syntax

DXGKCB_SAVEMEMORYFORHOTUPDATE DxgkcbSavememoryforhotupdate;

NTSTATUS DxgkcbSavememoryforhotupdate(
  IN_CONST_HANDLE hAdapter,
  IN_CONST_PDXGKARGCB_SAVEMEMORYFORHOTUPDATE pArgs
)
{...}

Parameters

hAdapter

[in] A handle to the DXGK adapter that is passed to DxgkDdiStartDevice.

pArgs

[in] A pointer to the DXGKARGCB_SAVEMEMORYFORHOTUPDATE structure that contains arguments for this callback.

Return Value

Returns STATUS_SUCCESS if the operation succeeds.

Remarks

Each call to DxgkCbSaveMemoryForHotUpdate saves a block of physical memory pages and optionally metadata, which the driver wants to associate with the memory block. When the pages are restored, the driver will get a separate call for each saved memory block together with metadata.

For convenience, the callback provides 3 options to save physical memory:

  • As an array of contiguous physical memory ranges (pDataMemoryRanges)
  • As an MDL (pDataMdl)
  • As virtual memory buffer (pData)

One (and only one) of the pointers to data (pDataMemoryRanges, pDataMdl or pData) must be not NULL.

Requirements

   
Minimum supported client Windows 10, version 1903
Header d3dkmddi.h
IRQL <= APC_LEVEL