According to UEFI spec, only bits 0-15 of CapsuleFlags are
meaningful and CapsuleGuid specific, CAPSULE_FLAGS_PERSIST_ACROSS_RESET
CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE/CAPSULE_FLAGS_INITIATE_RESET
defined in UEFI spec are in bits 16-31, they should not be parsed in
CapsuleFlags of ESRT.

CapsuleFlags
The capsule flags field contains the CapsuleGuid flags (bits 0-15)
as defined in the EFI_CAPSULE_HEADER that will be set in the capsule
header.

Cc: Michael D Kinney <michael.d.kin...@intel.com>
Cc: Jiewen Yao <jiewen....@intel.com>
Cc: Yonghong Zhu <yonghong....@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Star Zeng <star.z...@intel.com>
---
 MdeModulePkg/Application/CapsuleApp/CapsuleDump.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c 
b/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c
index c0197dd640e4..97f1893ef433 100644
--- a/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c
+++ b/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c
@@ -454,9 +454,6 @@ DumpEsrtEntry (
   Print(L"  FwVersion                - 0x%x\n", EsrtEntry->FwVersion);
   Print(L"  LowestSupportedFwVersion - 0x%x\n", 
EsrtEntry->LowestSupportedFwVersion);
   Print(L"  CapsuleFlags             - 0x%x\n", EsrtEntry->CapsuleFlags);
-  Print(L"    PERSIST_ACROSS_RESET   - 0x%x\n", EsrtEntry->CapsuleFlags & 
CAPSULE_FLAGS_PERSIST_ACROSS_RESET);
-  Print(L"    POPULATE_SYSTEM_TABLE  - 0x%x\n", EsrtEntry->CapsuleFlags & 
CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE);
-  Print(L"    INITIATE_RESET         - 0x%x\n", EsrtEntry->CapsuleFlags & 
CAPSULE_FLAGS_INITIATE_RESET);
   Print(L"  LastAttemptVersion       - 0x%x\n", EsrtEntry->LastAttemptVersion);
   Print(L"  LastAttemptStatus        - 0x%x (%a)\n", 
EsrtEntry->LastAttemptStatus, 
LastAttemptStatusToString(EsrtEntry->LastAttemptStatus));
 }
-- 
2.7.0.windows.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to