summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaszlo Ersek <lersek@redhat.com>2013-11-12 18:35:23 +0000
committerjljusten <jljusten@6f19259b-4bc3-4df7-8a09-765794883524>2013-11-12 18:35:23 +0000
commit9d35ac2611aecc7c6c28597e69cff18e20e40a05 (patch)
tree7aa1ed7be06496bae84de7b1135681dcd2cae7b5
parentd48ec970ad3fae99647fe4213294eb792e3239d2 (diff)
downloadedk2-platforms-9d35ac2611aecc7c6c28597e69cff18e20e40a05.tar.xz
OvmfPkg: indicate enablement of flash variables with a dedicated PCD
PcdFlashNvStorageVariableBase64 is used to arbitrate between QemuFlashFvbServicesRuntimeDxe and EmuVariableFvbRuntimeDxe, but even the latter driver sets it if we fall back to it. Allow code running later than the startup of these drivers to know about the availability of flash variables, through a dedicated PCD. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14843 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--OvmfPkg/OvmfPkg.dec1
-rw-r--r--OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf1
-rw-r--r--OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FwBlockService.c1
3 files changed, 3 insertions, 0 deletions
diff --git a/OvmfPkg/OvmfPkg.dec b/OvmfPkg/OvmfPkg.dec
index 01fe46943d..7bfd5c31ae 100644
--- a/OvmfPkg/OvmfPkg.dec
+++ b/OvmfPkg/OvmfPkg.dec
@@ -80,6 +80,7 @@
[PcdsDynamic, PcdsDynamicEx]
gUefiOvmfPkgTokenSpaceGuid.PcdEmuVariableEvent|0|UINT64|2
+ gUefiOvmfPkgTokenSpaceGuid.PcdOvmfFlashVariablesEnable|FALSE|BOOLEAN|0x10
[PcdsFeatureFlag]
gUefiOvmfPkgTokenSpaceGuid.PcdSecureBootEnable|FALSE|BOOLEAN|3
diff --git a/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf b/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf
index 81981f5941..e3e7176a41 100644
--- a/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf
+++ b/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FvbServicesRuntimeDxe.inf
@@ -77,6 +77,7 @@
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase
gUefiOvmfPkgTokenSpaceGuid.PcdOvmfFlashNvStorageEventLogBase
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64
+ gUefiOvmfPkgTokenSpaceGuid.PcdOvmfFlashVariablesEnable
[Depex]
diff --git a/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FwBlockService.c b/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FwBlockService.c
index 2ae6678751..7d26c41ccc 100644
--- a/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FwBlockService.c
+++ b/OvmfPkg/QemuFlashFvbServicesRuntimeDxe/FwBlockService.c
@@ -1222,5 +1222,6 @@ Returns:
);
ASSERT_EFI_ERROR (Status);
+ PcdSetBool (PcdOvmfFlashVariablesEnable, TRUE);
return EFI_SUCCESS;
}