From: Gerd Hoffmann Date: Fri, 9 Dec 2022 11:22:44 +0000 (+0100) Subject: OvmfPkg: fix PlatformConfig X-Git-Tag: edk2-stable202302~195 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=16acacf24c2c1fa2eff9148ae8ec952d74e3ab03;hp=d8d4abdff9096a69ff59d96ac4a8dd0e19e5cbcc OvmfPkg: fix PlatformConfig The Hii form is named "MainFormState" and the EFI variable is named "PlatformConfig". Take into account the different names. Fixes: aefcc91805fd ("OvmfPkg/PlatformDxe: Handle all requests in ExtractConfig and RouteConfig") Signed-off-by: Gerd Hoffmann --- diff --git a/OvmfPkg/PlatformDxe/Platform.c b/OvmfPkg/PlatformDxe/Platform.c index ac31fafbdc..e58e75eb22 100644 --- a/OvmfPkg/PlatformDxe/Platform.c +++ b/OvmfPkg/PlatformDxe/Platform.c @@ -258,7 +258,7 @@ ExtractConfig ( !HiiIsConfigHdrMatch ( Request, &gOvmfPlatformConfigGuid, - mVariableName + mHiiFormName ) ) { @@ -447,7 +447,7 @@ RouteConfig ( !HiiIsConfigHdrMatch ( Configuration, &gOvmfPlatformConfigGuid, - mVariableName + mHiiFormName ) ) { diff --git a/OvmfPkg/PlatformDxe/PlatformConfig.c b/OvmfPkg/PlatformDxe/PlatformConfig.c index f5ac2d0609..4058a324eb 100644 --- a/OvmfPkg/PlatformDxe/PlatformConfig.c +++ b/OvmfPkg/PlatformDxe/PlatformConfig.c @@ -22,6 +22,7 @@ // Name of the UEFI variable that we use for persistent storage. // CHAR16 mVariableName[] = L"PlatformConfig"; +CHAR16 mHiiFormName[] = L"MainFormState"; /** Serialize and persistently save platform configuration. diff --git a/OvmfPkg/PlatformDxe/PlatformConfig.h b/OvmfPkg/PlatformDxe/PlatformConfig.h index 5d9b457b1b..93d06a9a6b 100644 --- a/OvmfPkg/PlatformDxe/PlatformConfig.h +++ b/OvmfPkg/PlatformDxe/PlatformConfig.h @@ -51,5 +51,6 @@ PlatformConfigLoad ( #define PLATFORM_CONFIG_F_DOWNGRADE BIT63 extern CHAR16 mVariableName[]; +extern CHAR16 mHiiFormName[]; #endif // _PLATFORM_CONFIG_H_