Implement BlGetMappingsCount() routine

This commit is contained in:
2024-01-28 17:26:20 +01:00
parent 670a812649
commit b8acfe1b66
4 changed files with 30 additions and 0 deletions

View File

@@ -91,6 +91,28 @@ BlFreeMemoryPool(IN PVOID Memory)
return EfiSystemTable->BootServices->FreePool(Memory);
}
/**
* Returns the number of mappings in the page mapping structure.
*
* @param PageMap
* Supplies a pointer to the page mapping structure.
*
* @param NumberOfMappings
* Supplies a pointer to memory area where the number of mappings is returned.
*
* @return This routine does not return any value.
*
* @since XT 1.0
*/
XTCDECL
VOID
BlGetMappingsCount(IN PXTBL_PAGE_MAPPING PageMap,
OUT PULONG NumberOfMappings)
{
/* Return number of mappings */
*NumberOfMappings = PageMap->MapSize;
}
/**
* Returns the memory descriptors which define a memory map of all the physical memory ranges reserved by the UEFI.
*