//\r
if ((ConfigFormEntry->IfrData.SecurityStatus.Supported) &&\r
(ConfigFormEntry->IfrData.SecurityStatus.Enabled)) {\r
+\r
+ //\r
+ // Add PcdSkipHddPasswordPrompt to determin whether to skip password prompt.\r
+ // Due to board design, device may not power off during system warm boot, which result in\r
+ // security status remain unlocked status, hence we add device security status check here.\r
+ //\r
+ // If device is in the locked status, device keeps locked and system continues booting.\r
+ // If device is in the unlocked status, system is forced shutdown for security concern.\r
+ //\r
+ if (PcdGetBool (PcdSkipHddPasswordPrompt)) {\r
+ if (ConfigFormEntry->IfrData.SecurityStatus.Locked) {\r
+ return;\r
+ } else {\r
+ gRT->ResetSystem (EfiResetShutdown, EFI_SUCCESS, 0, NULL);\r
+ }\r
+ }\r
//\r
// As soon as the HDD password is in enabled state, we pop up a window to unlock hdd\r
// no matter it's really in locked or unlocked state.\r
MdePkg/MdePkg.dec\r
MdeModulePkg/MdeModulePkg.dec\r
CryptoPkg/CryptoPkg.dec\r
+ SecurityPkg/SecurityPkg.dec\r
\r
[LibraryClasses]\r
BaseLib\r
gEfiPciIoProtocolGuid ## CONSUMES\r
gEdkiiVariableLockProtocolGuid ## CONSUMES\r
\r
+[Pcd]\r
+ gEfiSecurityPkgTokenSpaceGuid.PcdSkipHddPasswordPrompt ## CONSUMES\r
+\r
[Depex]\r
gEfiVariableWriteArchProtocolGuid\r
\r
# @Prompt Skip Opal DXE driver password prompt.\r
gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalPasswordPrompt|FALSE|BOOLEAN|0x00010020\r
\r
+ ## Indicates if Hdd Password driver skip password prompt.<BR><BR>\r
+ # TRUE - Skip password prompt.<BR>\r
+ # FALSE - Does not skip password prompt.<BR>\r
+ # @Prompt Skip Hdd Password prompt.\r
+ gEfiSecurityPkgTokenSpaceGuid.PcdSkipHddPasswordPrompt|FALSE|BOOLEAN|0x00010021\r
+\r
[PcdsDynamic, PcdsDynamicEx]\r
\r
## This PCD indicates Hash mask for TPM 2.0. Bit definition strictly follows TCG Algorithm Registry.<BR><BR>\r