Hi Gerd,
I explain the reason why 47 here is since virtual addresses are sign-extended
in the commit message.
About the technical background, I also mentioned in the commit message " When
5-Level Paging is disabled and the PhysicalAddressBits retrived from CPU HOB
or CpuId is bigger than 47".
On Thu, Jan 11, 2024 at 04:59:47PM +0800, Dun Tan wrote:
> When creating smm page table, limit maximum
> supported physical address bits returned by
> CalculateMaximumSupportAddress() to 47 if
> 5-Level Paging is disabled.
> When 5-Level Paging is disabled and the
> PhysicalAddressBits retrived fro
.groups.io On Behalf Of duntan
Sent: Thursday, January 11, 2024 5:00 PM
To: devel@edk2.groups.io
Cc: Ni, Ray ; Laszlo Ersek ; Kumar, Rahul
R ; Gerd Hoffmann
Subject: [edk2-devel] [Patch V3] UefiCpuPkg:Limit PhysicalAddressBits in
special case
When creating smm page table, limit maximum supported
When creating smm page table, limit maximum
supported physical address bits returned by
CalculateMaximumSupportAddress() to 47 if
5-Level Paging is disabled.
When 5-Level Paging is disabled and the
PhysicalAddressBits retrived from CPU HOB or
CpuId is bigger than 47, and since virtual
addresses are