summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg/Universal
diff options
context:
space:
mode:
Diffstat (limited to 'IntelFrameworkModulePkg/Universal')
-rw-r--r--IntelFrameworkModulePkg/Universal/VariablePei/Variable.c8
-rw-r--r--IntelFrameworkModulePkg/Universal/VariablePei/Variable.h2
-rw-r--r--IntelFrameworkModulePkg/Universal/VariablePei/VariablePei.inf3
3 files changed, 10 insertions, 3 deletions
diff --git a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c
index d5881f5..aa43ae1 100644
--- a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c
+++ b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c
@@ -277,7 +277,8 @@ GetVariableStoreStatus (
)
{
- if (VarStoreHeader->Signature == VARIABLE_STORE_SIGNATURE &&
+
+ if (CompareGuid (&VarStoreHeader->Signature, &gEfiVariableGuid) &&
VarStoreHeader->Format == VARIABLE_STORE_FORMATTED &&
VarStoreHeader->State == VARIABLE_STORE_HEALTHY
) {
@@ -285,7 +286,10 @@ GetVariableStoreStatus (
return EfiValid;
}
- if (VarStoreHeader->Signature == 0xffffffff &&
+ if (((UINT32 *)(&VarStoreHeader->Signature))[0] == 0xffffffff &&
+ ((UINT32 *)(&VarStoreHeader->Signature))[1] == 0xffffffff &&
+ ((UINT32 *)(&VarStoreHeader->Signature))[2] == 0xffffffff &&
+ ((UINT32 *)(&VarStoreHeader->Signature))[3] == 0xffffffff &&
VarStoreHeader->Size == 0xffffffff &&
VarStoreHeader->Format == 0xff &&
VarStoreHeader->State == 0xff
diff --git a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.h b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.h
index 73cb491..31c855d 100644
--- a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.h
+++ b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.h
@@ -23,7 +23,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/PcdLib.h>
#include <Library/BaseMemoryLib.h>
#include <Library/PeiServicesTablePointerLib.h>
-#include <VariableFormat.h>
+#include <Guid/VariableFormat.h>
typedef struct {
VARIABLE_HEADER *CurrPtr;
diff --git a/IntelFrameworkModulePkg/Universal/VariablePei/VariablePei.inf b/IntelFrameworkModulePkg/Universal/VariablePei/VariablePei.inf
index 48e9efc..a83c310 100644
--- a/IntelFrameworkModulePkg/Universal/VariablePei/VariablePei.inf
+++ b/IntelFrameworkModulePkg/Universal/VariablePei/VariablePei.inf
@@ -99,6 +99,9 @@
gEfiPeiReadOnlyVariablePpiGuid # PPI ALWAYS_PRODUCED
gEfiPeiReadOnlyVariable2PpiGuid # PPI ALWAYS_PRODUCED
+[Guids]
+ gEfiVariableGuid
+
################################################################################
#
# Pcd DYNAMIC - list of PCDs that this module is coded for.