Skip to content

Latest commit

 

History

History
83 lines (63 loc) · 3.65 KB

nc-d3dumddi-pfnd3dddi_mapgpuvirtualaddresscb.md

File metadata and controls

83 lines (63 loc) · 3.65 KB
UID title description tech.root ms.date keywords ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames f1_keywords topic_type api_type api_location api_name
NC:d3dumddi.PFND3DDDI_MAPGPUVIRTUALADDRESSCB
PFND3DDDI_MAPGPUVIRTUALADDRESSCB (d3dumddi.h)
Learn more about the pfnMapGpuVirtualAddressCb function.
display
07/25/2023
PFND3DDDI_MAPGPUVIRTUALADDRESSCB callback function
PFND3DDDI_MAPGPUVIRTUALADDRESSCB, PFND3DDDI_MAPGPUVIRTUALADDRESSCB callback, d3dumddi/pfnMapGpuVirtualAddressCb, display.pfnmapgpuvirtualaddresscb, pfnMapGpuVirtualAddressCb, pfnMapGpuVirtualAddressCb callback function [Display Devices]
d3dumddi.h
D3dumddi.h
Desktop
Windows 10
Windows Server 2016
Windows
PFND3DDDI_MAPGPUVIRTUALADDRESSCB
d3dumddi/PFND3DDDI_MAPGPUVIRTUALADDRESSCB
APIRef
kbSyntax
UserDefined
d3dumddi.h
PFND3DDDI_MAPGPUVIRTUALADDRESSCB

PFND3DDDI_MAPGPUVIRTUALADDRESSCB callback function

-description

pfnMapGpuVirtualAddressCb maps GPU virtual address (VA) ranges to a specific allocation range or puts it to the Invalid or Zero state.

-parameters

-param hDevice

A handle to the display device.

-param unnamedParam2

[in/out] pDate is a pointer to a D3DDDI_MAPGPUVIRTUALADDRESS structure that describes the operation to perform.

-returns

pfnMapGpuVirtualAddressCb returns one of the following values:

Return code Description
S_OK The operation completed successfully.
E_PENDING The call was successful, but the operation is not finished. The caller must wait for the returned fence value before accessing the allocation.

This function might also return other values.

-remarks

The user-mode driver can specify a base GPU virtual address (VA) to map or let the video memory manager automatically pick one. When specifying a non-NULL BaseAddress value, the entire range from BaseAddress to BaseAddress+Size must be in a freed state or belong to a VA range that was obtained by calling pfnMapGpuVirtualAddressCb or pfnReserveGpuVirtualAddressCb. When Protection.Zero or Protection.NoAccess is specified, the VA range can't belong to a range that was obtained by calling pfnMapGpuVirtualAddressCb.

The user-mode driver can specify whether the mapping should allow for write and execute privileges in addition to read privileges, which always exist by default.

In linked display adapter (LDA) configuration, the paging queue defines a physical GPU whose page tables are modified, and the allocation handle (if not NULL) defines where the page table entries are pointing to. The allocation can be resident in any physical GPU memory segment.

The GPU VA range, which is allocated by the API, is freed when the allocation (the GPU VA is mapped to) is destroyed. The VA range can also be freed by calling PFND3DDDI_FREEGPUVIRTUALADDRESSCB, but this needs to be synchronized with allocation destruction if necessary.

-see-also

D3DDDI_MAPGPUVIRTUALADDRESS

pfnReserveGpuVirtualAddressCb