summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTim He <tim.he@intel.com>2015-06-10 09:14:40 +0000
committertimhe <timhe@Edk2>2015-06-10 09:14:40 +0000
commit927713c8f144ba0954d9d1138c2ca74d8ae594e6 (patch)
treea0094a4298a0b7f00947c6da5df6edc243274fee
parentda01d6a73ddca8167571786d36317e988084fdf0 (diff)
downloadedk2-927713c8f144ba0954d9d1138c2ca74d8ae594e6.tar.gz
Remove Runtime access attribute for PlatformInfo
variable, and fix the boot issue in case “Timeout” variable is corrupted. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Tim He <tim.he@intel.com> Reviewed-by: David Wei <david.wei@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2014.SP1@17611 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c5
-rw-r--r--Vlv2TbltDevicePkg/PlatformInfoDxe/PlatformInfoDxe.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c
index 057a328477..195d734189 100644
--- a/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c
+++ b/Vlv2TbltDevicePkg/Library/PlatformBdsLib/BdsPlatform.c
@@ -1609,6 +1609,11 @@ PlatformBdsPolicyBehavior (
UINTN BootOrderSize;
Timeout = PcdGet16 (PcdPlatformBootTimeOut);
+ if (Timeout > 10 ) {
+ //we think the Timeout variable is corrupted
+ Timeout = 10;
+ }
+
VarSize = sizeof(SYSTEM_CONFIGURATION);
Status = gRT->GetVariable(
NORMAL_SETUP_NAME,
diff --git a/Vlv2TbltDevicePkg/PlatformInfoDxe/PlatformInfoDxe.c b/Vlv2TbltDevicePkg/PlatformInfoDxe/PlatformInfoDxe.c
index 9400c34d53..8bdcaee7c9 100644
--- a/Vlv2TbltDevicePkg/PlatformInfoDxe/PlatformInfoDxe.c
+++ b/Vlv2TbltDevicePkg/PlatformInfoDxe/PlatformInfoDxe.c
@@ -159,7 +159,7 @@ PlatformInfoInit (
Status = gRT->SetVariable(
L"PlatformInfo",
&gEfiVlv2VariableGuid,
- EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_RUNTIME_ACCESS | EFI_VARIABLE_NON_VOLATILE,
+ EFI_VARIABLE_BOOTSERVICE_ACCESS | EFI_VARIABLE_NON_VOLATILE,
sizeof(EFI_PLATFORM_INFO_HOB),
PlatformInfoHobPtr
);