Hi,

> -    Pml4Entries = 1 << (mPhysMemAddressWidth - 39);
> +    if (TdIsEnabled ()) {
> +      Pml4Entries = 0x200;
> +    } else {
> +      Pml4Entries = 1 << (mPhysMemAddressWidth - 39);
> +    }

With the PlatformAddressWidthInitialization() update in patch #33 it
should not be needed to special-case TDX here.  You might need a check
for 5-level paging support (mPhysMemAddressWidth > 48) though, or just
cap Pml4Entries at 512 entries.

take care,
  Gerd



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#86889): https://edk2.groups.io/g/devel/message/86889
Mute This Topic: https://groups.io/mt/89252065/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to