{
BlMdPhysical,
BlMdVirtual,
+ BlMdTracker
} BL_MEMORY_DESCRIPTOR_TYPE;
typedef enum _BL_TRANSLATION_TYPE
BlMemoryUnknown = 0x00010000,
BlMemoryNonFixed = 0x00020000,
BlMemoryFixed = 0x00040000,
- BlMemoryReserved = 0x00080000,
- BlMemoryValidAllocationAttributes = BlMemoryNonFixed | BlMemoryFixed | BlMemoryReserved | BlMemoryUnknown,
+ BlMemoryBelow1MB = 0x00080000,
+ BlMemoryValidAllocationAttributes = BlMemoryNonFixed | BlMemoryFixed | BlMemoryBelow1MB | BlMemoryUnknown,
BlMemoryValidAllocationAttributeMask = 0x00FF0000,
//
_Out_opt_ PLARGE_INTEGER Frequency
);
+ULONGLONG
+BlArchGetPerformanceCounter (
+ VOID
+ );
+
/* RESOURCE LOCALE INTERNATIONALIZATION ROUTINES *****************************/
NTSTATUS
/* UTILITY ROUTINES **********************************************************/
+VOID
+BlArchCpuId (
+ _In_ ULONG Function,
+ _In_ ULONG SubFunction,
+ _Out_ INT* Result
+ );
+
+BOOLEAN
+BlArchIsCpuIdFunctionSupported (
+ _In_ ULONG Function
+ );
+
VOID
BlUtlUpdateProgress (
_In_ ULONG Percentage,
_In_ ULONGLONG Page
);
+PBL_MEMORY_DESCRIPTOR
+MmMdFindDescriptorFromMdl (
+ _In_ PBL_MEMORY_DESCRIPTOR_LIST MdList,
+ _In_ ULONG Flags,
+ _In_ ULONGLONG Page
+ );
+
NTSTATUS
MmMdCopyList (
_In_ PBL_MEMORY_DESCRIPTOR_LIST DestinationList,
);
NTSTATUS
+MmPaReleaseSelfMapPages (
+ _In_ PHYSICAL_ADDRESS Address
+ );
+
+NTSTATUS
+MmPaReserveSelfMapPages (
+ _Inout_ PPHYSICAL_ADDRESS PhysicalAddress,
+ _In_ ULONG Alignment,
+ _In_ ULONG PageCount
+ );
+NTSTATUS
BlMmFreePhysicalPages (
_In_ PHYSICAL_ADDRESS Address
);
/* VIRTUAL MEMORY ROUTINES ***************************************************/
+NTSTATUS
+MmSelectMappingAddress (
+ _Out_ PVOID* MappingAddress,
+ _In_ ULONGLONG Size,
+ _In_ ULONG AllocationAttributes,
+ _In_ ULONG Flags,
+ _In_ PHYSICAL_ADDRESS PhysicalAddress
+ );
+
+NTSTATUS
+MmMapPhysicalAddress (
+ _Inout_ PPHYSICAL_ADDRESS PhysicalAddress,
+ _Out_ PVOID* VirtualAddress,
+ _Inout_ PULONGLONG Size,
+ _In_ ULONG CacheAttributes
+ );
+
+NTSTATUS
+MmUnmapVirtualAddress (
+ _Inout_ PVOID* VirtualAddress,
+ _Inout_ PULONGLONG Size
+ );
+
NTSTATUS
BlMmMapPhysicalAddressEx (
_In_ PVOID* VirtualAddress,
_Out_ PPHYSICAL_ADDRESS PhysicalAddress
);
+BOOLEAN
+MmArchTranslateVirtualAddress (
+ _In_ PVOID VirtualAddress,
+ _Out_opt_ PPHYSICAL_ADDRESS PhysicalAddress,
+ _Out_opt_ PULONG CachingFlags
+ );
+
/* BLOCK ALLOCATOR ROUTINES **************************************************/
NTSTATUS