diff options
Diffstat (limited to 'SecurityPkg')
-rw-r--r-- | SecurityPkg/SecurityPkg.dec | 6 | ||||
-rw-r--r-- | SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c | 4 | ||||
-rw-r--r-- | SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf | 3 |
3 files changed, 13 insertions, 0 deletions
diff --git a/SecurityPkg/SecurityPkg.dec b/SecurityPkg/SecurityPkg.dec index 7ae42ea150..a46d88d392 100644 --- a/SecurityPkg/SecurityPkg.dec +++ b/SecurityPkg/SecurityPkg.dec @@ -428,6 +428,12 @@ # @Prompt Possible TPM2 Interrupt Number buffer
gEfiSecurityPkgTokenSpaceGuid.PcdTpm2PossibleIrqNumBuf|{0x00, 0x00, 0x00, 0x00}|VOID*|0x0001001D
+ ## Indicates if Opal DXE driver skip unlock device flow.<BR><BR>
+ # TRUE - Skip unlock device flow.<BR>
+ # FALSE - Does not skip unlock device flow.<BR>
+ # @Prompt Skip Opal DXE driver unlock device flow.
+ gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalDxeUnlock|FALSE|BOOLEAN|0x00010020
+
[PcdsDynamic, PcdsDynamicEx]
## This PCD indicates Hash mask for TPM 2.0. Bit definition strictly follows TCG Algorithm Registry.<BR><BR>
diff --git a/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c b/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c index 38268539fb..734c5f06ff 100644 --- a/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c +++ b/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c @@ -988,6 +988,10 @@ OpalDriverRequestPassword ( IsLocked = OpalDeviceLocked (&Dev->OpalDisk.SupportedAttributes, &Dev->OpalDisk.LockingFeature);
+ if (IsLocked && PcdGetBool (PcdSkipOpalDxeUnlock)) {
+ return;
+ }
+
while (Count < MAX_PASSWORD_TRY_COUNT) {
Password = OpalDriverPopUpPasswordInput (Dev, PopUpString, NULL, &PressEsc);
if (PressEsc) {
diff --git a/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf b/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf index cfa55dded7..11e58b95cd 100644 --- a/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf +++ b/SecurityPkg/Tcg/Opal/OpalPassword/OpalPasswordDxe.inf @@ -75,5 +75,8 @@ [Guids]
gEfiEndOfDxeEventGroupGuid ## CONSUMES ## Event
+[Pcd]
+ gEfiSecurityPkgTokenSpaceGuid.PcdSkipOpalDxeUnlock ## CONSUMES
+
[Depex]
gEfiHiiStringProtocolGuid AND gEfiHiiDatabaseProtocolGuid
|