From 6cfbf7adff681490789ce9c20bf9344aee6a225e Mon Sep 17 00:00:00 2001 From: davidhuang Date: Fri, 20 Nov 2009 04:01:15 +0000 Subject: 1. PI SMBIOS Checkin. Major change include: 1) Produce PI SMBIOS protocol in MdeModulePkg 2) Update all consumers (in CorePkgs and native platform pkgs) to consume SMBIOS protocol instead of DataHub 3) Pass ECC tool; Verify Nt32, Duet, Unix platform git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9455 6f19259b-4bc3-4df7-8a09-765794883524 --- .../Universal/BdsDxe/BootMaint/BmLib.c | 61 +--------------------- 1 file changed, 1 insertion(+), 60 deletions(-) (limited to 'IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint') diff --git a/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BmLib.c b/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BmLib.c index f575592dbc..7a4183d6b3 100644 --- a/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BmLib.c +++ b/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BmLib.c @@ -1,7 +1,7 @@ /** @file Utility routines used by boot maintenance modules. -Copyright (c) 2004 - 2008, Intel Corporation.
+Copyright (c) 2004 - 2009, Intel Corporation.
All rights reserved. This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -431,64 +431,5 @@ EfiLibStrFromDatahub ( IN EFI_DEVICE_PATH_PROTOCOL *DevPath ) { - EFI_STATUS Status; - UINT16 *Desc; - EFI_DATA_HUB_PROTOCOL *Datahub; - UINT64 Count; - EFI_DATA_RECORD_HEADER *Record; - EFI_SUBCLASS_TYPE1_HEADER *DataHdr; - EFI_GUID MiscGuid; - EFI_MISC_ONBOARD_DEVICE_DATA *Ob; - EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *Port; - EFI_TIME CurTime; - - CopyGuid (&MiscGuid, &gEfiMiscSubClassGuid); - - Status = gBS->LocateProtocol ( - &gEfiDataHubProtocolGuid, - NULL, - (VOID **) &Datahub - ); - if (EFI_ERROR (Status)) { - return NULL; - } - - Status = gRT->GetTime (&CurTime, NULL); - if (EFI_ERROR (Status)) { - return NULL; - } - - Count = 0; - do { - Status = Datahub->GetNextRecord (Datahub, &Count, NULL, &Record); - - if (EFI_ERROR (Status)) { - break; - } - - if (Record->DataRecordClass == EFI_DATA_RECORD_CLASS_DATA && CompareGuid (&Record->DataRecordGuid, &MiscGuid)) { - // - // This record is what we need - // - DataHdr = (EFI_SUBCLASS_TYPE1_HEADER *) (Record + 1); - if (EFI_MISC_ONBOARD_DEVICE_RECORD_NUMBER == DataHdr->RecordType) { - Ob = (EFI_MISC_ONBOARD_DEVICE_DATA *) (DataHdr + 1); - if (BdsLibMatchDevicePaths ((EFI_DEVICE_PATH_PROTOCOL *) &Ob->OnBoardDevicePath, DevPath)) { - GetProducerString (&Record->ProducerName, Ob->OnBoardDeviceDescription, &Desc); - return Desc; - } - } - - if (EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_RECORD_NUMBER == DataHdr->RecordType) { - Port = (EFI_MISC_PORT_INTERNAL_CONNECTOR_DESIGNATOR_DATA *) (DataHdr + 1); - if (BdsLibMatchDevicePaths ((EFI_DEVICE_PATH_PROTOCOL *) &Port->PortPath, DevPath)) { - GetProducerString (&Record->ProducerName, Port->PortExternalConnectorDesignator, &Desc); - return Desc; - } - } - } - - } while (TimeCompare (&Record->LogTime, &CurTime) && Count != 0); - return NULL; } -- cgit v1.2.3