summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
979b7d8)
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1277
The failure is caused by data type conversion between UINTN and UINT64,
which is checked in at
63ebde8ef6d4ff497d054ccc010904ecd4441198.
Cc: Star Zeng <star.zeng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Jian J Wang <jian.j.wang@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
IN EFI_PHYSICAL_ADDRESS Address\r
)\r
{\r
IN EFI_PHYSICAL_ADDRESS Address\r
)\r
{\r
\r
//\r
// There must be at least one guarded page before and/or after given\r
\r
//\r
// There must be at least one guarded page before and/or after given\r
UINT64 Address;\r
UINT64 GuardPage;\r
INTN Level;\r
UINT64 Address;\r
UINT64 GuardPage;\r
INTN Level;\r
UINTN GuardPageNumber;\r
\r
if (mGuardedMemoryMap == 0 ||\r
UINTN GuardPageNumber;\r
\r
if (mGuardedMemoryMap == 0 ||\r
- Pages = EFI_SIZE_TO_PAGES (MaxAddress - MemoryMapEntry->PhysicalStart);\r
- Pages -= MemoryMapEntry->NumberOfPages;\r
+ Pages = EFI_SIZE_TO_PAGES ((UINTN)(MaxAddress - MemoryMapEntry->PhysicalStart));\r
+ Pages -= (INTN)MemoryMapEntry->NumberOfPages;\r
while (Pages > 0) {\r
if (Bitmap == 0) {\r
EndAddress = MemoryMapEntry->PhysicalStart +\r
while (Pages > 0) {\r
if (Bitmap == 0) {\r
EndAddress = MemoryMapEntry->PhysicalStart +\r
- EFI_PAGES_TO_SIZE (MemoryMapEntry->NumberOfPages);\r
+ EFI_PAGES_TO_SIZE ((UINTN)MemoryMapEntry->NumberOfPages);\r
Bitmap = GetGuardedMemoryBits (EndAddress, GUARDED_HEAP_MAP_ENTRY_BITS);\r
}\r
\r
Bitmap = GetGuardedMemoryBits (EndAddress, GUARDED_HEAP_MAP_ENTRY_BITS);\r
}\r
\r