Skip to content

Latest commit

 

History

History
71 lines (58 loc) · 1.81 KB

nf-wdm-mmgetmdlvirtualaddress.md

File metadata and controls

71 lines (58 loc) · 1.81 KB
UID tech.root title ms.date targetos description prerelease req.assembly req.construct-type req.ddi-compliance req.dll req.header req.idl req.include-header req.irql req.kmdf-ver req.lib req.max-support req.namespace req.redist req.target-min-winverclnt req.target-min-winversvr req.target-type req.type-library req.umdf-ver req.unicode-ansi topic_type api_type api_location api_name f1_keywords dev_langs
NF:wdm.MmGetMdlVirtualAddress
MmGetMdlVirtualAddress
07/16/2021
Windows
Learn more about: MmGetMdlVirtualAddress
false
function
wdm.h
Any level (see Remarks)
Windows 2000
apiref
HeaderDef
wdm.h
MmGetMdlVirtualAddress
MmGetMdlVirtualAddress
wdm/MmGetMdlVirtualAddress
c++

-description

The MmGetMdlVirtualAddress macro returns the base virtual address of a buffer described by an MDL.

-syntax

PVOID
MmGetMdlVirtualAddress (
    _In_ PMDL Mdl
    )

-parameters

-param Mdl [in]

Pointer to an MDL that describes the buffer for which to return the initial virtual address.

-remarks

MmGetMdlVirtualAddress returns the starting virtual address of the MDL.

MmGetMdlVirtualAddress returns a virtual address that is not necessarily valid in the current thread context. Lower-level drivers should not attempt to use the returned virtual address to access memory, particularly user memory space.

The returned address, used as an index to a physical address entry in the MDL, can be input to MapTransfer.

Callers of MmGetMdlVirtualAddress can be running at any IRQL. Usually, the caller is running at IRQL = DISPATCH_LEVEL because this routine is commonly called to obtain the CurrentVa parameter to MapTransfer.