UEFI HII: Merge UEFI HII support changes from branch.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4601 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@@ -69,7 +69,7 @@
|
||||
BaseMemoryLib
|
||||
UefiDriverEntryPoint
|
||||
UefiLib
|
||||
FrameworkHiiLib
|
||||
HiiLib
|
||||
DebugLib
|
||||
BaseLib
|
||||
PcdLib
|
||||
@@ -83,12 +83,11 @@
|
||||
|
||||
[Protocols]
|
||||
gEfiWinNtIoProtocolGuid # PROTOCOL_NOTIFY SOMETIMES_CONSUMED
|
||||
gEfiHiiProtocolGuid # PROTOCOL ALWAYS_CONSUMED
|
||||
gEfiDataHubProtocolGuid # PROTOCOL ALWAYS_CONSUMED
|
||||
|
||||
[Pcd.common]
|
||||
gEfiNt32PkgTokenSpaceGuid.PcdWinNtMemorySize
|
||||
|
||||
[Depex]
|
||||
gEfiDataHubProtocolGuid AND gEfiHiiProtocolGuid
|
||||
gEfiDataHubProtocolGuid
|
||||
|
@@ -94,9 +94,6 @@
|
||||
<Protocol Usage="ALWAYS_CONSUMED">
|
||||
<ProtocolCName>gEfiDataHubProtocolGuid</ProtocolCName>
|
||||
</Protocol>
|
||||
<Protocol Usage="ALWAYS_CONSUMED">
|
||||
<ProtocolCName>gEfiHiiProtocolGuid</ProtocolCName>
|
||||
</Protocol>
|
||||
<ProtocolNotify Usage="SOMETIMES_CONSUMED">
|
||||
<ProtocolNotifyCName>gEfiWinNtIoProtocolGuid</ProtocolNotifyCName>
|
||||
</ProtocolNotify>
|
||||
|
@@ -148,8 +148,6 @@ Returns:
|
||||
{
|
||||
EFI_MISC_SUBCLASS_DRIVER_DATA RecordData;
|
||||
EFI_DATA_HUB_PROTOCOL *DataHub;
|
||||
EFI_HII_PROTOCOL *Hii;
|
||||
EFI_HII_PACKAGES *PackageList;
|
||||
EFI_HII_HANDLE HiiHandle;
|
||||
EFI_STATUS Status;
|
||||
UINTN Index;
|
||||
@@ -180,23 +178,9 @@ Returns:
|
||||
return EFI_DEVICE_ERROR;
|
||||
}
|
||||
//
|
||||
// Locate hii protocol.
|
||||
//
|
||||
Status = gBS->LocateProtocol (&gEfiHiiProtocolGuid, NULL, &Hii);
|
||||
|
||||
if (EFI_ERROR (Status)) {
|
||||
DEBUG ((EFI_D_ERROR, "Could not locate Hii protocol. %r\n", Status));
|
||||
return Status;
|
||||
} else if (Hii == NULL) {
|
||||
DEBUG ((EFI_D_ERROR, "LocateProtocol(Hii) returned NULL pointer!\n"));
|
||||
return EFI_DEVICE_ERROR;
|
||||
}
|
||||
//
|
||||
// Add our default strings to the HII database. They will be modified later.
|
||||
//
|
||||
PackageList = PreparePackages (1, &gEfiMiscSubClassGuid, MiscSubclassStrings);
|
||||
Status = Hii->NewPack (Hii, PackageList, &HiiHandle);
|
||||
FreePool (PackageList);
|
||||
HiiLibAddPackagesToHiiDatabase (1, &gEfiMiscSubClassGuid, NULL, &HiiHandle, MiscSubclassStrings);
|
||||
|
||||
if (EFI_ERROR (Status)) {
|
||||
DEBUG ((EFI_D_ERROR, "Could not log default strings to Hii. %r\n", Status));
|
||||
|
Reference in New Issue
Block a user