summaryrefslogtreecommitdiff
path: root/Platform/Intel
diff options
context:
space:
mode:
authorMichael D Kinney <michael.d.kinney@intel.com>2019-06-20 13:10:01 -0700
committerMichael D Kinney <michael.d.kinney@intel.com>2019-07-01 16:13:28 -0700
commitd6211390793fbd0a89b14001c43e0ef942c85425 (patch)
tree6f86e1380404a41c8c3128e17d1d50f3fa5410a2 /Platform/Intel
parent3dad9700aabdbe0838af5a99a292272ea7108480 (diff)
Vlv2TbltDevicePkg: Update boot mode/state behaviors
* Add platform specific PcdBootState PCD to remove Intel Framework dependency * Set PcdUserPhysicalPresence to TRUE to Enable UEFI Secure Boot Setup Menus * Remove unused code when NOCS_S3_SUPPORT is not set * Update PlatformBootManagerLib to not perform a connect all when FastBoot is enabled. * Add support for BOOT_ON_FLASH_UPDATE * Remove logic in CheckSystemConfigSave() that was generating an ASSERT() when setup changes were saved. Cc: Zailiang Sun <zailiang.sun@intel.com> Cc: Yi Qian <yi.qian@intel.com> Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-By: Zailiang Sun <zailiang.sun@intel.com>
Diffstat (limited to 'Platform/Intel')
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/BdsPlatform.c33
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/DxePlatformBootManagerLib.inf4
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf1
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c99
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.c8
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h27
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec8
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc2
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc2
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc2
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe.inf1
-rw-r--r--Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/SetupInfoRecords.c51
12 files changed, 51 insertions, 187 deletions
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/BdsPlatform.c b/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/BdsPlatform.c
index 4dd3827a..7fbbf281 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/BdsPlatform.c
+++ b/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/BdsPlatform.c
@@ -1,7 +1,7 @@
/** @file
This file include all platform action which can be customized by IBV/OEM.
-Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
@@ -1164,7 +1164,7 @@ PlatformBootManagerBeforeConsole (
// Fill ConIn/ConOut in Full Configuration boot mode
//
gBootMode = GetBootModeHob();
- DEBUG ((DEBUG_INFO, "PlatformBootManagerInit - %x\n", gBootMode));
+ DEBUG ((DEBUG_INFO, "PlatformBootManagerBeforeConsole: BootMode = %x\n", gBootMode));
if (gBootMode == BOOT_WITH_FULL_CONFIGURATION ||
gBootMode == BOOT_WITH_DEFAULT_SETTINGS ||
@@ -1263,7 +1263,18 @@ ConnectSequence (
IN EFI_BOOT_MODE BootMode
)
{
- EfiBootManagerConnectAll ();
+ switch (BootMode) {
+ case BOOT_ASSUMING_NO_CONFIGURATION_CHANGES:
+ case BOOT_WITH_MINIMAL_CONFIGURATION:
+ case BOOT_ON_S4_RESUME:
+ break;
+ case BOOT_WITH_FULL_CONFIGURATION:
+ case BOOT_WITH_FULL_CONFIGURATION_PLUS_DIAGNOSTICS:
+ case BOOT_WITH_DEFAULT_SETTINGS:
+ default:
+ EfiBootManagerConnectAll ();
+ break;
+ }
}
/**
@@ -1311,6 +1322,7 @@ PlatformBootManagerAfterConsole (
VOID
)
{
+ EFI_STATUS Status;
EFI_BOOT_MODE LocalBootMode;
DEBUG ((DEBUG_INFO, "PlatformBootManagerAfterConsole\n"));
@@ -1319,7 +1331,7 @@ PlatformBootManagerAfterConsole (
// Get current Boot Mode
//
LocalBootMode = gBootMode;
- DEBUG ((DEBUG_INFO, "Current local bootmode - %x\n", LocalBootMode));
+ DEBUG ((DEBUG_INFO, "PlatformBootManagerAfterConsole: BootMode = %x\n", gBootMode));
//
// Logo show
@@ -1372,6 +1384,19 @@ PlatformBootManagerAfterConsole (
break;
}
+ //
+ // Use a DynamicHii type pcd to save the boot status, which is used to
+ // control configuration mode, such as FULL/MINIMAL/NO_CHANGES configuration.
+ //
+ DEBUG ((DEBUG_INFO, "PcdBootState = %d\n", PcdGetBool(PcdBootState)));
+ if (PcdGetBool(PcdBootState)) {
+ Status = PcdSetBoolS(PcdBootState, FALSE);
+ if (EFI_ERROR (Status)) {
+ DEBUG ((DEBUG_ERROR, "Set PcdBootState to FALSE failed.\n"));
+ }
+ DEBUG ((DEBUG_INFO, "PcdBootState = %d\n", PcdGetBool(PcdBootState)));
+ }
+
Print (L"Press F7 for BootMenu!\n");
EfiBootManagerRefreshAllBootOption ();
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/DxePlatformBootManagerLib.inf b/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/DxePlatformBootManagerLib.inf
index b04169ad..0579a186 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/DxePlatformBootManagerLib.inf
+++ b/Platform/Intel/Vlv2TbltDevicePkg/Library/DxePlatformBootManagerLib/DxePlatformBootManagerLib.inf
@@ -1,7 +1,7 @@
### @file
# Component name for module DxePlatformBootManagerLib
#
-# Copyright (c) 2017, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.<BR>
#
# SPDX-License-Identifier: BSD-2-Clause-Patent
#
@@ -48,6 +48,7 @@
MdeModulePkg/MdeModulePkg.dec
SecurityPkg/SecurityPkg.dec
MinPlatformPkg/MinPlatformPkg.dec
+ Vlv2TbltDevicePkg/PlatformPkg.dec
[Pcd]
gMinPlatformPkgTokenSpaceGuid.PcdTpm2Enable ## CONSUMES
@@ -66,6 +67,7 @@
gMinPlatformPkgTokenSpaceGuid.PcdTrustedConsoleInputDevicePath ## CONSUMES
gMinPlatformPkgTokenSpaceGuid.PcdTrustedConsoleOutputDevicePath ## CONSUMES
gMinPlatformPkgTokenSpaceGuid.PcdTrustedStorageDevicePath ## CONSUMES
+ gPlatformModuleTokenSpaceGuid.PcdBootState
[Sources]
BdsPlatform.c
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf b/Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf
index a9ef744e..9fee6913 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf
@@ -84,7 +84,6 @@
gEfiGlobalVariableGuid
gEfiEventExitBootServicesGuid
gEfiVlv2VariableGuid
- gEfiSecureBootEnableDisableGuid
gEfiEndOfDxeEventGroupGuid
[Protocols]
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c
index 9fdcb620..5269b1ed 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c
@@ -1,10 +1,8 @@
/** @file
- Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
-
- SPDX-License-Identifier: BSD-2-Clause-Patent
+ Copyright (c) 2004 - 2019, Intel Corporation. All rights reserved.<BR>
-
+ SPDX-License-Identifier: BSD-2-Clause-Patent
Module Name:
@@ -84,6 +82,7 @@ CapsulePpiNotifyCallback (
if (Status == EFI_SUCCESS) {
if (Capsule->CheckCapsuleUpdate ((EFI_PEI_SERVICES**)PeiServices) == EFI_SUCCESS) {
BootMode = BOOT_ON_FLASH_UPDATE;
+ DEBUG ((EFI_D_ERROR, "Setting BootMode to BOOT_ON_FLASH_UPDATE\n"));
Status = (*PeiServices)->SetBootMode((const EFI_PEI_SERVICES **)PeiServices, BootMode);
ASSERT_EFI_ERROR (Status);
}
@@ -93,98 +92,6 @@ CapsulePpiNotifyCallback (
return Status;
}
-#ifdef NOCS_S3_SUPPORT
-EFI_STATUS
-UpdateBootMode (
- IN CONST EFI_PEI_SERVICES **PeiServices
- )
-{
- EFI_STATUS Status;
- EFI_BOOT_MODE BootMode;
- UINT16 SleepType;
- CHAR16 *strBootMode;
-
- Status = (*PeiServices)->GetBootMode(PeiServices, &BootMode);
- ASSERT_EFI_ERROR (Status);
- if (BootMode == BOOT_IN_RECOVERY_MODE){
- return Status;
- }
-
- //
- // Let's assume things are OK if not told otherwise
- //
- BootMode = BOOT_WITH_FULL_CONFIGURATION;
-
- if (GetSleepTypeAfterWakeup (PeiServices, &SleepType)) {
- switch (SleepType) {
- case V_PCH_ACPI_PM1_CNT_S3:
- BootMode = BOOT_ON_S3_RESUME;
- Status = (*PeiServices)->NotifyPpi (PeiServices, &mCapsuleNotifyList[0]);
- ASSERT_EFI_ERROR (Status);
- break;
-
- case V_PCH_ACPI_PM1_CNT_S4:
- BootMode = BOOT_ON_S4_RESUME;
- break;
-
- case V_PCH_ACPI_PM1_CNT_S5:
- BootMode = BOOT_ON_S5_RESUME;
- break;
- } // switch (SleepType)
- }
-
- if (IsFastBootEnabled (PeiServices)) {
- DEBUG ((EFI_D_INFO, "Prioritizing Boot mode to BOOT_WITH_MINIMAL_CONFIGURATION\n"));
- PrioritizeBootMode (&BootMode, BOOT_WITH_MINIMAL_CONFIGURATION);
- }
-
- switch (BootMode) {
- case BOOT_WITH_FULL_CONFIGURATION:
- strBootMode = L"BOOT_WITH_FULL_CONFIGURATION";
- break;
- case BOOT_WITH_MINIMAL_CONFIGURATION:
- strBootMode = L"BOOT_WITH_MINIMAL_CONFIGURATION";
- break;
- case BOOT_ASSUMING_NO_CONFIGURATION_CHANGES:
- strBootMode = L"BOOT_ASSUMING_NO_CONFIGURATION_CHANGES";
- break;
- case BOOT_WITH_FULL_CONFIGURATION_PLUS_DIAGNOSTICS:
- strBootMode = L"BOOT_WITH_FULL_CONFIGURATION_PLUS_DIAGNOSTICS";
- break;
- case BOOT_WITH_DEFAULT_SETTINGS:
- strBootMode = L"BOOT_WITH_DEFAULT_SETTINGS";
- break;
- case BOOT_ON_S4_RESUME:
- strBootMode = L"BOOT_ON_S4_RESUME";
- break;
- case BOOT_ON_S5_RESUME:
- strBootMode = L"BOOT_ON_S5_RESUME";
- break;
- case BOOT_ON_S2_RESUME:
- strBootMode = L"BOOT_ON_S2_RESUME";
- break;
- case BOOT_ON_S3_RESUME:
- strBootMode = L"BOOT_ON_S3_RESUME";
-
- break;
- case BOOT_ON_FLASH_UPDATE:
- strBootMode = L"BOOT_ON_FLASH_UPDATE";
- break;
- case BOOT_IN_RECOVERY_MODE:
- strBootMode = L"BOOT_IN_RECOVERY_MODE";
- break;
- default:
- strBootMode = L"Unknown boot mode";
- } // switch (BootMode)
-
- DEBUG ((EFI_D_ERROR, "Setting BootMode to %s\n", strBootMode));
- Status = (*PeiServices)->SetBootMode(PeiServices, BootMode);
- ASSERT_EFI_ERROR (Status);
-
- return Status;
-}
-#endif
-
/**
Get sleep type after wakeup
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.c b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.c
index aa03f6ea..90998871 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.c
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.c
@@ -813,14 +813,6 @@ PeiInitPlatform (
sizeof (EFI_PLATFORM_INFO_HOB)
);
- //
- // Set the new boot mode for MRC
- //
-#ifdef NOCS_S3_SUPPORT
- Status = UpdateBootMode (PeiServices);
- ASSERT_EFI_ERROR (Status);
-#endif
-
DEBUG((EFI_D_INFO, "Setup MMIO size ... \n\n"));
//
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h
index e1817b28..4f71e519 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h
@@ -1,11 +1,8 @@
/*++
- Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
-
- SPDX-License-Identifier: BSD-2-Clause-Patent
-
-
+ Copyright (c) 2004 - 2019, Intel Corporation. All rights reserved.<BR>
+ SPDX-License-Identifier: BSD-2-Clause-Patent
**/
@@ -24,26 +21,6 @@ typedef struct {
#define STALL_PEIM_FROM_THIS(a) CR (a, STALL_CALLBACK_STATE_INFORMATION, StallNotify, STALL_PEIM_SIGNATURE)
-#ifdef NOCS_S3_SUPPORT
-
-/**
- Peform the boot mode determination logic
- If the box is closed, then
- 1. If it's first time to boot, it's boot with full config .
- 2. If the ChassisIntrution is selected, force to be a boot with full config
- 3. Otherwise it's boot with no change.
-
- @param PeiServices General purpose services available to every PEIM.
- @param BootMode The detected boot mode.
-
- @retval EFI_SUCCESS if the boot mode could be set
-**/
-EFI_STATUS
-UpdateBootMode (
- IN CONST EFI_PEI_SERVICES **PeiServices
- );
-#endif
-
/**
This function reset the entire platform, including all processor and devices, and
reboots the system.
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec
index 5b255f4b..a5c7062c 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec
@@ -161,6 +161,14 @@
gPlatformModuleTokenSpaceGuid.PcdInConfigMode|FALSE|BOOLEAN|0x80000001
gPlatformModuleTokenSpaceGuid.PcdConnectUSBKeyboardonWaitForKeyStroke|FALSE|BOOLEAN|0x80000002
gPlatformModuleTokenSpaceGuid.PcdEnableWatchdogSwSmiInputValue|0|UINT8|0x80000003
+
+ ## Indicates if the machine has completed one boot cycle before.
+ # After the complete boot, BootState will be set to FALSE.<BR><BR>
+ # TRUE - The complete boot cycle has not happened before.<BR>
+ # FALSE - The complete boot cycle has happened before.<BR>
+ # @Prompt Boot State Flag
+ gPlatformModuleTokenSpaceGuid.PcdBootState|TRUE|BOOLEAN|0x80000004
+
#
#device firmware update support
#
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
index e4c6750c..2123745c 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
@@ -680,6 +680,7 @@
[PcdsDynamicHii.common.DEFAULT]
gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut|L"Timeout"|gEfiGlobalVariableGuid|0x0|5 # Variable: L"Timeout"
gEfiMdePkgTokenSpaceGuid.PcdHardwareErrorRecordLevel|L"HwErrRecSupport"|gEfiGlobalVariableGuid|0x0|1 # Variable: L"HwErrRecSupport"
+ gPlatformModuleTokenSpaceGuid.PcdBootState|L"BootState"|gPlatformModuleTokenSpaceGuid|0x0|TRUE
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdS3BootScriptTablePrivateDataPtr|0x0
@@ -733,6 +734,7 @@
gEfiVLVTokenSpaceGuid.PcdCpuLockBoxDataAddress|0
gEfiVLVTokenSpaceGuid.PcdCpuSmramCpuDataAddress|0
gEfiVLVTokenSpaceGuid.PcdCpuLockBoxSize|0
+ gEfiSecurityPkgTokenSpaceGuid.PcdUserPhysicalPresence|TRUE
[PcdsDynamicExDefault.X64.DEFAULT]
!if $(RECOVERY_ENABLE)
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
index f5795e5a..086668d5 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
@@ -677,6 +677,7 @@
[PcdsDynamicHii.common.DEFAULT]
gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut|L"Timeout"|gEfiGlobalVariableGuid|0x0|5 # Variable: L"Timeout"
gEfiMdePkgTokenSpaceGuid.PcdHardwareErrorRecordLevel|L"HwErrRecSupport"|gEfiGlobalVariableGuid|0x0|1 # Variable: L"HwErrRecSupport"
+ gPlatformModuleTokenSpaceGuid.PcdBootState|L"BootState"|gPlatformModuleTokenSpaceGuid|0x0|TRUE
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdS3BootScriptTablePrivateDataPtr|0x0
@@ -730,6 +731,7 @@
gEfiVLVTokenSpaceGuid.PcdCpuLockBoxDataAddress|0
gEfiVLVTokenSpaceGuid.PcdCpuSmramCpuDataAddress|0
gEfiVLVTokenSpaceGuid.PcdCpuLockBoxSize|0
+ gEfiSecurityPkgTokenSpaceGuid.PcdUserPhysicalPresence|TRUE
[PcdsDynamicExDefault.X64.DEFAULT]
!if $(RECOVERY_ENABLE)
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
index a930a85a..5f2dd65e 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
@@ -679,6 +679,7 @@
[PcdsDynamicHii.common.DEFAULT]
gEfiMdePkgTokenSpaceGuid.PcdPlatformBootTimeOut|L"Timeout"|gEfiGlobalVariableGuid|0x0|5 # Variable: L"Timeout"
gEfiMdePkgTokenSpaceGuid.PcdHardwareErrorRecordLevel|L"HwErrRecSupport"|gEfiGlobalVariableGuid|0x0|1 # Variable: L"HwErrRecSupport"
+ gPlatformModuleTokenSpaceGuid.PcdBootState|L"BootState"|gPlatformModuleTokenSpaceGuid|0x0|TRUE
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdS3BootScriptTablePrivateDataPtr|0x0
@@ -732,6 +733,7 @@
gEfiVLVTokenSpaceGuid.PcdCpuLockBoxDataAddress|0
gEfiVLVTokenSpaceGuid.PcdCpuSmramCpuDataAddress|0
gEfiVLVTokenSpaceGuid.PcdCpuLockBoxSize|0
+ gEfiSecurityPkgTokenSpaceGuid.PcdUserPhysicalPresence|TRUE
[PcdsDynamicExDefault.X64.DEFAULT]
!if $(RECOVERY_ENABLE)
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe.inf b/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe.inf
index b7455744..85e8b1e8 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe.inf
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe.inf
@@ -93,7 +93,6 @@
gEfiIfrTianoGuid ## CONSUMES ## Guid
gEfiPlatformInfoGuid
gEfiNormalSetupGuid
- gEfiSecureBootEnableDisableGuid
gOsSelectionVariableGuid
gEfiGlobalVariableGuid
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/SetupInfoRecords.c b/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/SetupInfoRecords.c
index efd4a723..be99356d 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/SetupInfoRecords.c
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/SetupInfoRecords.c
@@ -1448,60 +1448,9 @@ CheckSystemConfigLoad(SYSTEM_CONFIGURATION *SystemConfigPtr)
}
}
-
-//
-// "SecureBootEnable" variable for the Secure boot feature enable/disable.
-//
-#define EFI_SECURE_BOOT_ENABLE_NAME L"SecureBootEnable"
-extern EFI_GUID gEfiSecureBootEnableDisableGuid;
-
-
VOID
CheckSystemConfigSave(SYSTEM_CONFIGURATION *SystemConfigPtr)
{
- EFI_STATUS Status;
- UINT8 SecureBootCfg;
- BOOLEAN SecureBootNotFound;
- UINTN DataSize;
-
-
- //
- // Secure Boot configuration changes
- //
- DataSize = sizeof(SecureBootCfg);
- SecureBootNotFound = FALSE;
- Status = gRT->GetVariable (
- EFI_SECURE_BOOT_ENABLE_NAME,
- &gEfiSecureBootEnableDisableGuid,
- NULL,
- &DataSize,
- &SecureBootCfg
- );
-
- if (EFI_ERROR(Status)) {
- SecureBootNotFound = TRUE;
- }
- if (SecureBootNotFound) {
- Status = gRT->GetVariable (
- EFI_SECURE_BOOT_ENABLE_NAME,
- &gEfiSecureBootEnableDisableGuid,
- NULL,
- &DataSize,
- &SecureBootCfg
- );
- ASSERT_EFI_ERROR(Status);
- }
- if ((SecureBootCfg) != SystemConfigPtr->SecureBoot) {
- SecureBootCfg = !SecureBootCfg;
- Status = gRT->SetVariable (
- EFI_SECURE_BOOT_ENABLE_NAME,
- &gEfiSecureBootEnableDisableGuid,
- EFI_VARIABLE_NON_VOLATILE | EFI_VARIABLE_BOOTSERVICE_ACCESS,
- sizeof (UINT8),
- &SecureBootCfg
- );
- }
-
}
VOID