From 60b519456cf01beb269bf864a37fa2acdc53f003 Mon Sep 17 00:00:00 2001 From: Michael Kubacki Date: Fri, 8 Apr 2022 11:53:29 -0400 Subject: MdeModulePkg/VariableFlashInfoLib: Add initial library REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3479 Adds a new library class VariableFlashInfoLib that abstracts access to variable flash information. The instance provided first attempts to retrieve information from the Variable Flash Info HOB. If that HOB is not present, it falls back to the PCDs defined in MdeModulePkg. This fall back behavior provides backward compatibility for platforms that only provide PCDs but also allows platforms that need to dynamically provide the information using the Variable Flash Info HOB to do so at runtime. Cc: Jian J Wang Cc: Hao A Wu Cc: Liming Gao Signed-off-by: Michael Kubacki Acked-by: Ard Biesheuvel Reviewed-by: Liming Gao Reviewed-by: Sami Mujawar --- MdeModulePkg/MdeModulePkg.dsc | 2 ++ 1 file changed, 2 insertions(+) (limited to 'MdeModulePkg/MdeModulePkg.dsc') diff --git a/MdeModulePkg/MdeModulePkg.dsc b/MdeModulePkg/MdeModulePkg.dsc index b1d8346186..90a0a7ec4a 100644 --- a/MdeModulePkg/MdeModulePkg.dsc +++ b/MdeModulePkg/MdeModulePkg.dsc @@ -103,6 +103,7 @@ DisplayUpdateProgressLib|MdeModulePkg/Library/DisplayUpdateProgressLibGraphics/DisplayUpdateProgressLibGraphics.inf VariablePolicyHelperLib|MdeModulePkg/Library/VariablePolicyHelperLib/VariablePolicyHelperLib.inf MmUnblockMemoryLib|MdePkg/Library/MmUnblockMemoryLib/MmUnblockMemoryLibNull.inf + VariableFlashInfoLib|MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf [LibraryClasses.EBC.PEIM] IoLib|MdePkg/Library/PeiIoLibCpuIo/PeiIoLibCpuIo.inf @@ -440,6 +441,7 @@ MdeModulePkg/Library/FmpAuthenticationLibNull/FmpAuthenticationLibNull.inf MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf MdeModulePkg/Library/DxeCapsuleLibFmp/DxeRuntimeCapsuleLib.inf + MdeModulePkg/Library/BaseVariableFlashInfoLib/BaseVariableFlashInfoLib.inf [Components.IA32, Components.X64, Components.AARCH64] MdeModulePkg/Universal/EbcDxe/EbcDxe.inf -- cgit