audk/MdeModulePkg/Core
Taylor Beebe 408e463135 MdeModulePkg: Memory Bin Range Update Accounts for Guard Page
When finding a free page range for allocation, if the found range
starts below the tracked memory bin address range, the lowest
memory bin address is updated which will not include the guard page if
present. When CoreConvertPagesWithGuard() is called on the range
being allocated, the memory range is adjusted to include guard
pages which can push it out of the memory bin address range and
cause the memory type statistics to be unaltered.

This patch updates the lowest memory bin address range to account for
the guard page if NeedGuard is TRUE so the memory type statistics
are updated correctly.

Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Taylor Beebe <t@taylorbeebe.com>
Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
2023-09-18 21:21:32 +00:00
..
Dxe MdeModulePkg: Memory Bin Range Update Accounts for Guard Page 2023-09-18 21:21:32 +00:00
DxeIplPeim MdeModulePkg/DxeIpl ARM AARCH64: Switch to generic handoff code 2023-06-26 09:11:53 +00:00
Pei MdeModulePkg/Core/Pei: set AprioriCount=0 before walking through next FV 2023-05-24 12:59:54 +00:00
PiSmmCore MdeModulePkg: Remove other attribute protection in UnsetGuardPage 2023-06-30 11:07:40 +05:30
RuntimeDxe MdeModulePkg/RuntimeDxe: clear mVirtualMapMaxIndex 2022-02-07 05:31:17 +00:00