Huomautus
Tämän sivun käyttö edellyttää valtuutusta. Voit yrittää kirjautua sisään tai vaihtaa hakemistoa.
Tämän sivun käyttö edellyttää valtuutusta. Voit yrittää vaihtaa hakemistoa.
Maps physical address space into the logical address space of an IOMMU_DMA_DOMAIN.
Syntax
IOMMU_MAP_LOGICAL_RANGE_EX IommuMapLogicalRangeEx;
NTSTATUS IommuMapLogicalRangeEx(
[in] PIOMMU_DMA_DOMAIN Domain,
[in] ULONG Permissions,
[in] PIOMMU_MAP_PHYSICAL_ADDRESS PhysicalAddressToMap,
[in, optional] PIOMMU_DMA_LOGICAL_ADDRESS ExplicitLogicalAddress,
[in, optional] PIOMMU_DMA_LOGICAL_ADDRESS MinLogicalAddress,
[in, optional] PIOMMU_DMA_LOGICAL_ADDRESS MaxLogicalAddress,
[out] PIOMMU_DMA_LOGICAL_ADDRESS LogicalAddressOut
)
{...}
Parameters
[in] Domain
A pointer to the IOMMU_DMA_DOMAIN that the mapped logical address will belong to. The domain must be of type DomainTypeTranslate. For more information about domain types, see IOMMU_DMA_DOMAIN_TYPE.
[in] Permissions
A bit-field representing the permissions to be set for the range being mapped. See Remarks for the available permission bits.
[in] PhysicalAddressToMap
The IOMMU_MAP_PHYSICAL_ADDRESS that will be mapped to the domain.
[in, optional] ExplicitLogicalAddress
The domain logical address that the physical address should be mapped to. If the domain was not created with a registered logical allocator, then this field is required. If the domain was created with a registered logical allocator that does not support explicit logical address allocation, then this field must be NULL.
[in, optional] MinLogicalAddress
The minimum (inclusive) allowable logical address that the physical address should be mapped to. If the domain was not created with a registered logical allocator, then this field will be ignored.
[in, optional] MaxLogicalAddress
The maximum (inclusive) allowable logical address that the physical address should be mapped to. If the domain was not created with a registered logical allocator, then this field will be ignored.
[out] LogicalAddressOut
Returns the resulting logical address from the mapping.
Return value
STATUS_SUCCESS if the operation is successful. Possible error return values include the following status codes.
Return code | Description |
---|---|
STATUS_INVALID_PARAMETER_1 | The domain provided is not of type DomainTypeTranslate. |
STATUS_INVALID_PARAMETER_3 | The IOMMU_MAP_PHYSICAL_ADDRESS provided does not represent physical memory that is page-aligned and has a size that is a multiple of PAGE_SIZE. |
STATUS_INVALID_PARAMETER_4 | The ExplicitLogicalAddress provided is not page-aligned. |
STATUS_INVALID_PARAMETER_MIX | The min and max logical addresses provided could not be satisfied. |
STATUS_IN_USE | The ExplicitLogicalAddress is already mapped or partially mapped. |
STATUS_NOT_SUPPORTED | An ExplicitLogicalAddress was provided for a domain with a logical allocator that does not allow explicit logical address allocation. Or an ExplicitLogicalAddress was not provided for a domain with no logical allocator. |
For more information, see NTSTATUS Values.
Remarks
To unmap the logical address created by IOMMU_MAP_LOGICAL_RANGE_EX, use IOMMU_UNMAP_LOGICAL_RANGE; there currently is no Ex equivalent for logical address range unmapping.
The permissions field is a bitfield that describes the access permissions for the pages to be mapped.
The bits are defined as follows:
Bit 0 = Read Access
Bit 1 = Write Access
Bits 31-2 = Reserved (0)
Requirements
Requirement | Value |
---|---|
Minimum supported server | Windows Server 2022 |
Header | wdm.h (include Wdm.h) |