From: "Sun, Zailiang" <zailiang.sun@intel.com>
To: "devel@edk2.groups.io" <devel@edk2.groups.io>,
"Kinney, Michael D" <michael.d.kinney@intel.com>
Cc: "Qian, Yi" <yi.qian@intel.com>
Subject: Re: [edk2-devel] [edk2-platforms Patch 11/14] Vlv2TbltDevicePkg: Update boot mode/state behaviors
Date: Mon, 1 Jul 2019 04:08:24 +0000 [thread overview]
Message-ID: <7CB7EF03E15B5D48981329A508747A9850C90592@SHSMSX104.ccr.corp.intel.com> (raw)
In-Reply-To: <20190701025553.18596-12-michael.d.kinney@intel.com>
Reviewed-By: Zailiang Sun <zailiang.sun@intel.com>
-----Original Message-----
From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of Michael D Kinney
Sent: Monday, July 01, 2019 10:56 AM
To: devel@edk2.groups.io
Cc: Sun, Zailiang <zailiang.sun@intel.com>; Qian, Yi <yi.qian@intel.com>
Subject: [edk2-devel] [edk2-platforms Patch 11/14] 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>
---
.../DxePlatformBootManagerLib/BdsPlatform.c | 33 ++++++-
.../DxePlatformBootManagerLib.inf | 4 +-
.../PlatformDxe/PlatformDxe.inf | 1 -
.../Vlv2TbltDevicePkg/PlatformPei/BootMode.c | 99 +------------------ .../Vlv2TbltDevicePkg/PlatformPei/Platform.c | 8 -- .../Vlv2TbltDevicePkg/PlatformPei/Platform.h | 27 +----
.../Intel/Vlv2TbltDevicePkg/PlatformPkg.dec | 8 ++
.../Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc | 2 +
.../Vlv2TbltDevicePkg/PlatformPkgIA32.dsc | 2 +
.../Vlv2TbltDevicePkg/PlatformPkgX64.dsc | 2 +
.../PlatformSetupDxe/PlatformSetupDxe.inf | 1 -
.../PlatformSetupDxe/SetupInfoRecords.c | 51 ----------
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 4dd3827a6e..7fbbf281c6 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 b04169ad33..0579a18660 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 @@ [Packages]
MdeModulePkg/MdeModulePkg.dec
SecurityPkg/SecurityPkg.dec
MinPlatformPkg/MinPlatformPkg.dec
+ Vlv2TbltDevicePkg/PlatformPkg.dec
[Pcd]
gMinPlatformPkgTokenSpaceGuid.PcdTpm2Enable ## CONSUMES
@@ -66,6 +67,7 @@ [Pcd]
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 a9ef744ef7..9fee691365 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformDxe/PlatformDxe.inf
@@ -84,7 +84,6 @@ [Guids]
gEfiGlobalVariableGuid
gEfiEventExitBootServicesGuid
gEfiVlv2VariableGuid
- gEfiSecureBootEnableDisableGuid
gEfiEndOfDxeEventGroupGuid
[Protocols]
diff --git a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c
index 9fdcb620a3..5269b1ed39 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/BootMode.c
@@ -1,11 +1,9 @@
/** @file
- Copyright (c) 2004 - 2018, Intel Corporation. All rights reserved.<BR>
-
+ 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 aa03f6ea95..90998871dc 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 e1817b28c6..4f71e519e0 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPei/Platform.h
@@ -1,12 +1,9 @@
/*++
- Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
-
+ 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 5b255f4b05..a5c7062cbb 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkg.dec
@@ -161,6 +161,14 @@ [PcdsDynamic,PcdsDynamicEx]
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 e4c6750c70..2123745ccd 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgGccX64.dsc
@@ -680,6 +680,7 @@ [PcdsPatchableInModule.common] [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"|gPlatformModul
+ eTokenSpaceGuid|0x0|TRUE
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdS3BootScriptTablePrivateDataPtr|0x0
@@ -733,6 +734,7 @@ [PcdsDynamicExDefault.common.DEFAULT]
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 f5795e5ab0..086668d570 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgIA32.dsc
@@ -677,6 +677,7 @@ [PcdsPatchableInModule.common] [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"|gPlatformModul
+ eTokenSpaceGuid|0x0|TRUE
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdS3BootScriptTablePrivateDataPtr|0x0
@@ -730,6 +731,7 @@ [PcdsDynamicExDefault.common.DEFAULT]
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 a930a85a35..5f2dd65ec8 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformPkgX64.dsc
@@ -679,6 +679,7 @@ [PcdsPatchableInModule.common] [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"|gPlatformModul
+ eTokenSpaceGuid|0x0|TRUE
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdS3BootScriptTablePrivateDataPtr|0x0
@@ -732,6 +733,7 @@ [PcdsDynamicExDefault.common.DEFAULT]
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 b745574421..85e8b1e8d6 100644
--- a/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe.inf
+++ b/Platform/Intel/Vlv2TbltDevicePkg/PlatformSetupDxe/PlatformSetupDxe
+++ .inf
@@ -93,7 +93,6 @@ [Guids]
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 efd4a723e1..be99356d0f 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
--
2.21.0.windows.1
next prev parent reply other threads:[~2019-07-01 4:08 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-01 2:55 [edk2-platforms Patch 00/14] Vlv2TbltDevicePkg: Remove Intel Framework dependencies Michael D Kinney
2019-07-01 2:55 ` [edk2-platforms Patch 01/14] Vlv2DeviceRefCodePkg: Add gEfiSmmIchnDispatchProtocolGuid Michael D Kinney
2019-07-01 4:06 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 02/14] Vlv2TbltDevicePkg: Reduce Intel Framework dependencies Michael D Kinney
2019-07-01 4:06 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 03/14] Vlv2TbltDevicePkg: Remove unused modules/libraries Michael D Kinney
2019-07-01 4:07 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 04/14] Vlv2TbltDevicePkg: Switch from ISA to SIO modules Michael D Kinney
2019-07-01 4:07 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 05/14] Vlv2TbltDevicePkg: Switch to CPU I/O 2 Protocol Michael D Kinney
2019-07-01 4:07 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 06/14] Vlv2TbltDevicePkg: Remove use of PS/2 Policy Protocol Michael D Kinney
2019-07-01 4:07 ` [edk2-devel] " Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 07/14] Vlv2TbltDevicePkg: Remove use of BIOS ID tools Michael D Kinney
2019-07-01 4:07 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 08/14] Vlv2TbltDevicePkg: Remove use of Data Hub Protocol Michael D Kinney
2019-07-01 4:08 ` [edk2-devel] " Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 09/14] Vlv2TbltDevicePkg: Use PI Spec SMBUS2 PPI Michael D Kinney
2019-07-01 4:08 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 10/14] Vlv2TbltDevicePkg: Switch to MdeModulePkg BdsDxe Michael D Kinney
2019-07-01 4:08 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 11/14] Vlv2TbltDevicePkg: Update boot mode/state behaviors Michael D Kinney
2019-07-01 4:08 ` Sun, Zailiang [this message]
2019-07-01 2:55 ` [edk2-platforms Patch 12/14] Vlv2TbltDevicePkg/PlatformSmm: Switch to PI SMM Protocols Michael D Kinney
2019-07-01 4:08 ` [edk2-devel] " Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 13/14] Vlv2TbltDevicePkg: Change to PI Spec ACPI Table Protocol Michael D Kinney
2019-07-01 4:08 ` Sun, Zailiang
2019-07-01 2:55 ` [edk2-platforms Patch 14/14] Vlv2TbltDevicePkg/PlatformInitPei: Update MemoryTypeInformation Michael D Kinney
2019-07-01 4:08 ` Sun, Zailiang
2019-07-01 4:04 ` [edk2-devel] [edk2-platforms Patch 00/14] Vlv2TbltDevicePkg: Remove Intel Framework dependencies Gary Lin
2019-07-01 23:07 ` Michael D Kinney
2019-07-02 9:48 ` Gary Lin
2019-07-02 16:49 ` Michael D Kinney
2019-07-02 21:11 ` Michael D Kinney
2019-07-03 3:57 ` Gary Lin
2019-07-09 3:52 ` Michael D Kinney
2019-07-09 6:04 ` Gary Lin
2019-07-10 3:38 ` Michael D Kinney
2019-07-10 4:14 ` Gary Lin
2019-07-10 5:01 ` Michael D Kinney
2019-07-10 7:10 ` Gary Lin
2019-07-10 19:27 ` Michael D Kinney
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7CB7EF03E15B5D48981329A508747A9850C90592@SHSMSX104.ccr.corp.intel.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox