]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg/DxeIplPeim: Initialize pointer PageMapLevel5Entry
authorZhang, Shenglei <shenglei.zhang@intel.com>
Thu, 15 Aug 2019 02:23:14 +0000 (10:23 +0800)
committerHao A Wu <hao.a.wu@intel.com>
Fri, 16 Aug 2019 01:03:18 +0000 (09:03 +0800)
Initialize PageMapLevel5Entry at the beginning of the function.

This commit will fix a GCC 4.8.5 build failure introduced by commit
b3527dedc3951f061c5a73cb4fb2b0f95f47e08b.

OvmfPkg build failure wtih gcc 4.8.5 still exists at latest edk2 version.
The commit 46f8a6891606746ca8b1e684ac379ce271306dc0 seems not to fix
the build failure completely.

Cc: Dandan Bi <dandan.bi@intel.com>
Signed-off-by: Shenglei Zhang <shenglei.zhang@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
MdeModulePkg/Core/DxeIplPeim/X64/VirtualMemory.c

index 2389f3eb485b2e5919ac01439ec0b4a8f800a804..516cf908bc886e8c34ab549694cb9beea1896d16 100644 (file)
@@ -652,6 +652,11 @@ CreateIdentityMappingPageTables (
   UINT64                                        AddressEncMask;\r
   IA32_CR4                                      Cr4;\r
 \r
+  //\r
+  // Set PageMapLevel5Entry to suppress incorrect compiler/analyzer warnings\r
+  //\r
+  PageMapLevel5Entry = NULL;\r
+\r
   //\r
   // Make sure AddressEncMask is contained to smallest supported address field\r
   //\r