Refactor XPA detection API

This commit is contained in:
2025-12-04 23:07:59 +01:00
parent 8054bb915a
commit c710ec4688
3 changed files with 18 additions and 18 deletions

View File

@@ -204,20 +204,6 @@ MM::Paging::GetPageMapBasicRoutines(VOID)
return &PageMapBasicRoutines;
}
/**
* Gets the current paging mode level.
*
* @return This routine returns 5 if 5-level paging (XPA) is enabled, otherwise 4 for 4-level paging.
*
* @since XT 1.0
*/
XTAPI
USHORT
MM::Paging::GetPageMapLevel()
{
return PmlRoutines->GetXpaStatus() ? 5 : 4;
}
/**
* Gets the page map routines for eXtended Physical Addressing (XPA) mode.
*
@@ -358,6 +344,20 @@ MM::Paging::GetPteVirtualAddress(IN PMMPTE PtePointer)
return PmlRoutines->GetPteVirtualAddress(PtePointer);
}
/**
* Gets current status of eXtended Physical Addressing (XPA).
*
* @return This routine returns TRUE if PAE or LA57 (XPA) is enabled, or FALSE otherwise.
*
* @since XT 1.0
*/
XTAPI
BOOLEAN
MM::Paging::GetXpaStatus()
{
return PmlRoutines->GetXpaStatus();
}
/**
* Detects if eXtended Physical Addressing (XPA) is enabled and initializes page map support.
*