summaryrefslogtreecommitdiffstats
path: root/SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c
diff options
context:
space:
mode:
Diffstat (limited to 'SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c')
-rw-r--r--SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c87
1 files changed, 0 insertions, 87 deletions
diff --git a/SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c b/SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c
index b07e38c144..31e1aa2240 100644
--- a/SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c
+++ b/SecurityPkg/Tcg/Opal/OpalPassword/OpalHiiCallbacks.c
@@ -16,56 +16,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include "OpalHii.h"
/**
- Get Opal var name.
- The return Value must be freed by caller if not NULL
-
- @param OpalDisk The disk.
- @param Prefix The prefix string.
-
- @retval The var name string.
-
-**/
-CHAR16*
-OpalDriverGetOpalVarName(
- OPAL_DISK *OpalDisk,
- const CHAR16 *Prefix
- )
-{
- OPAL_DRIVER_DEVICE* Dev;
- UINTN PrefixLen;
- UINTN NameLen;
- UINTN VarNameLen;
- CHAR16* VarName;
-
- Dev = DRIVER_DEVICE_FROM_OPALDISK(OpalDisk);
- if (Dev == NULL) {
- return NULL;
- }
-
- PrefixLen = StrLen(Prefix);
-
- NameLen = 0;
- if (Dev->Name16 != NULL) {
- NameLen = StrLen(Dev->Name16);
- }
-
- VarNameLen = PrefixLen + NameLen;
-
- VarName = (CHAR16*)AllocateZeroPool((VarNameLen + 1) * sizeof(CHAR16));
- if (VarName == NULL) {
- return NULL;
- }
-
- CopyMem(VarName, Prefix, PrefixLen * sizeof(CHAR16));
- if (Dev->Name16 != NULL) {
- CopyMem(VarName + PrefixLen, Dev->Name16, NameLen * sizeof(CHAR16));
- }
- VarName[VarNameLen] = 0;
-
- return VarName;
-}
-
-/**
Get the driver image handle.
@retval the driver image handle.
@@ -80,43 +30,6 @@ HiiGetDriverImageHandleCB(
}
/**
- Check whether enable feature or not.
-
- @retval Return the disk number.
-
-**/
-UINT8
-HiiGetNumConfigRequiredOpalDisksCB(
- VOID
- )
-{
- UINT8 NumDisks;
- UINT8 NumLockedOpalDisks;
- OPAL_DISK *OpalDisk;
- UINT8 Index;
-
- NumLockedOpalDisks = 0;
-
- NumDisks = GetDeviceCount();
-
- for (Index = 0; Index < NumDisks; Index++) {
- OpalDisk = HiiGetOpalDiskCB(Index);
-
- if (OpalDisk != NULL) {
- if (!OpalFeatureEnabled (&OpalDisk->SupportedAttributes, &OpalDisk->LockingFeature)) {
- DEBUG ((DEBUG_INFO, "Ignoring disk %u because feature is disabled or health has already been inspected\n", Index));
- } else if (OpalDeviceLocked (&OpalDisk->SupportedAttributes, &OpalDisk->LockingFeature)) {
- NumLockedOpalDisks++;
- }
- }
- }
-
- return NumLockedOpalDisks;
-}
-
-
-
-/**
Returns the opaque pointer to a physical disk context.
@param DiskIndex Input the disk index.