From 5fd5fcd321e3d778aa51f1a47732c8d886c1ff4c Mon Sep 17 00:00:00 2001 From: qwang12 Date: Mon, 21 Jan 2008 14:42:45 +0000 Subject: 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 --- Nt32Pkg/CpuRuntimeDxe/Cpu.c | 19 +++---------------- Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.inf | 5 ++--- Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.msa | 3 --- 3 files changed, 5 insertions(+), 22 deletions(-) (limited to 'Nt32Pkg/CpuRuntimeDxe') diff --git a/Nt32Pkg/CpuRuntimeDxe/Cpu.c b/Nt32Pkg/CpuRuntimeDxe/Cpu.c index 2dff9024c9..48e12ecc1c 100644 --- a/Nt32Pkg/CpuRuntimeDxe/Cpu.c +++ b/Nt32Pkg/CpuRuntimeDxe/Cpu.c @@ -421,10 +421,7 @@ Returns: UINT32 HeaderSize; UINT32 TotalSize; EFI_DATA_HUB_PROTOCOL *DataHub; - EFI_HII_PROTOCOL *Hii; - EFI_HII_HANDLE StringHandle; - EFI_HII_PACKAGES *PackageList; - + EFI_HII_HANDLE HiiHandle; // // Locate DataHub protocol. @@ -434,14 +431,6 @@ Returns: return; } - // - // Locate DataHub protocol. - // - Status = gBS->LocateProtocol (&gEfiHiiProtocolGuid, NULL, &Hii); - if (EFI_ERROR (Status)) { - return; - } - // // Initialize data record header // @@ -456,10 +445,8 @@ Returns: // // Initialize strings to HII database // - PackageList = PreparePackages (1, &gEfiProcessorProducerGuid, CpuStrings); - Status = Hii->NewPack (Hii, PackageList, &StringHandle); - ASSERT (!EFI_ERROR (Status)); - FreePool (PackageList); + HiiLibAddPackagesToHiiDatabase (1, &gEfiProcessorProducerGuid, NULL, &HiiHandle, CpuStrings); + CopyMem (RecordBuffer.Raw, &mCpuDataRecordHeader, HeaderSize); diff --git a/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.inf b/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.inf index ee76efa60b..837a3ae18e 100644 --- a/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.inf +++ b/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.inf @@ -48,7 +48,7 @@ MemoryAllocationLib BaseMemoryLib UefiDriverEntryPoint - FrameworkHiiLib + HiiLib DebugLib [Guids] @@ -58,10 +58,9 @@ [Protocols] gEfiWinNtIoProtocolGuid # PROTOCOL_NOTIFY SOMETIMES_CONSUMED gEfiDataHubProtocolGuid # PROTOCOL SOMETIMES_CONSUMED - gEfiHiiProtocolGuid # PROTOCOL SOMETIMES_CONSUMED gEfiWinNtIoProtocolGuid # PROTOCOL ALWAYS_CONSUMED gEfiCpuIoProtocolGuid # PROTOCOL ALWAYS_PRODUCED gEfiCpuArchProtocolGuid # PROTOCOL ALWAYS_PRODUCED [Depex] - gEfiDataHubProtocolGuid AND gEfiHiiProtocolGuid + gEfiDataHubProtocolGuid diff --git a/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.msa b/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.msa index f0f22f9540..4237a1e837 100644 --- a/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.msa +++ b/Nt32Pkg/CpuRuntimeDxe/CpuRuntimeDxe.msa @@ -62,9 +62,6 @@ gEfiWinNtIoProtocolGuid - - gEfiHiiProtocolGuid - gEfiDataHubProtocolGuid -- cgit v1.2.3