#ifndef _NTRTL_H
// rev
/**
* The RtlCmDecodeMemIoResource routine decodes a memory or I/O resource descriptor and returns its length and translated start address.
*
* \param ResourceDescriptor A pointer to the CM_PARTIAL_RESOURCE_DESCRIPTOR to decode.
* \param TranslatedAddress An optional pointer to a variable that receives the start address of the resource.
* \return ULONGLONG The length, in bytes, of the decoded resource.
*/
NTSYSAPI
ULONGLONG
NTAPI
RtlCmDecodeMemIoResource(
_In_ const VOID *ResourceDescriptor,
_Out_opt_ PULONGLONG TranslatedAddress
);
View code on GitHub// wdm.h
NTSYSAPI ULONGLONG RtlCmDecodeMemIoResource(
[in] PCM_PARTIAL_RESOURCE_DESCRIPTOR Descriptor,
[out, optional] PULONGLONG Start
);
View the official Windows Driver Kit DDI referenceNo description available.
The RtlCmDecodeMemIoResource routine provides the starting address and length of a CM_PARTIAL_RESOURCE_DESCRIPTOR structure that describes a range of memory or I/O port addresses.
Descriptor [in]A pointer to the CM_PARTIAL_RESOURCE_DESCRIPTOR structure to provide the starting address and length for.
Start [out, optional]A pointer to a variable that receives the starting address of the range of memory or I/O port addresses.
RtlCmDecodeMemIoResource returns the length of the address range, in bytes.
The Type member of the CM_PARTIAL_RESOURCE_DESCRIPTOR structure must be CmResourceTypeMemory, CmResourceTypeMemoryLarge, or CmResourceTypePort.
CM_PARTIAL_RESOURCE_DESCRIPTOR