From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) (using TLSv1 with cipher CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 0F0981A1DF7 for ; Mon, 29 Aug 2016 22:55:06 -0700 (PDT) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga103.jf.intel.com with ESMTP; 29 Aug 2016 22:55:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.30,254,1470726000"; d="scan'208";a="1043233560" Received: from fmsmsx107.amr.corp.intel.com ([10.18.124.205]) by orsmga002.jf.intel.com with ESMTP; 29 Aug 2016 22:55:03 -0700 Received: from fmsmsx119.amr.corp.intel.com (10.18.124.207) by fmsmsx107.amr.corp.intel.com (10.18.124.205) with Microsoft SMTP Server (TLS) id 14.3.248.2; Mon, 29 Aug 2016 22:54:46 -0700 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by FMSMSX119.amr.corp.intel.com (10.18.124.207) with Microsoft SMTP Server (TLS) id 14.3.248.2; Mon, 29 Aug 2016 22:54:46 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.109]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.250]) with mapi id 14.03.0248.002; Tue, 30 Aug 2016 13:54:44 +0800 From: "Fan, Jeff" To: "Wu, Hao A" , "edk2-devel@lists.01.org" , "Gao, Liming" Thread-Topic: [PATCH 1/3] IntelFrameworkModulePkg: Use IsZeroGuid API for zero GUID checking Thread-Index: AQHSAmdRayAxGDAf8EeTF2UPPQxPKKBhAS6Q Date: Tue, 30 Aug 2016 05:54:43 +0000 Message-ID: <542CF652F8836A4AB8DBFAAD40ED192A4A1D714E@shsmsx102.ccr.corp.intel.com> References: <1472524574-17732-1-git-send-email-hao.a.wu@intel.com> <1472524574-17732-2-git-send-email-hao.a.wu@intel.com> In-Reply-To: <1472524574-17732-2-git-send-email-hao.a.wu@intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiYTNlMGVjOTItMzVlYi00MjZlLWI1ZTItMGJlZWQwZWY4NjA3IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6Ijd0MFpqV0lRVnB1UFpLZ1V4K3phXC9IeXRvNFRoaEYwUG9yREhnckJmWCswPSJ9 x-ctpclassification: CTP_IC x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH 1/3] IntelFrameworkModulePkg: Use IsZeroGuid API for zero GUID checking X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 30 Aug 2016 05:55:06 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Jeff Fan -----Original Message----- From: Wu, Hao A=20 Sent: Tuesday, August 30, 2016 10:36 AM To: edk2-devel@lists.01.org; Gao, Liming Cc: Wu, Hao A; Fan, Jeff Subject: [PATCH 1/3] IntelFrameworkModulePkg: Use IsZeroGuid API for zero G= UID checking Instead of comparing a GUID with gZeroGuid via the CompareGuid API, the com= mit uses the IsZeroGuid API to check if the given GUID is a zero GUID. Cc: Jeff Fan Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu --- IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.c | 4 ++-- IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.h | 4 +--- IntelFrameworkModulePkg/Universal/DataHubDxe/DataHubDxe.inf | 6 +----- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.c b/Intel= FrameworkModulePkg/Universal/DataHubDxe/DataHub.c index 91f7c7e..916586f 100644 --- a/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.c +++ b/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.c @@ -2,7 +2,7 @@ This code produces the Data Hub protocol. It preloads the data hub with status information copied in from PEI HOBs. =20 -Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.
This program and the accompanying materials =20 are licensed and made available under the terms and conditions of the BSD = License =20 which accompanies this distribution. The full text of the license may be = found at =20 @@ -139,7 +139,7 @@ DataHubLogData ( for (Link =3D GetFirstNode(Head); Link !=3D Head; Link =3D GetNextNode(H= ead, Link)) { FilterEntry =3D FILTER_ENTRY_FROM_LINK (Link); if (((FilterEntry->ClassFilter & DataRecordClass) !=3D 0) && - (CompareGuid (&FilterEntry->FilterDataRecordGuid, &gZeroGuid) ||=20 + (IsZeroGuid (&FilterEntry->FilterDataRecordGuid) || CompareGuid (&FilterEntry->FilterDataRecordGuid, DataRecordGuid))= ) { gBS->SignalEvent (FilterEntry->Event); } diff --git a/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.h b/Intel= FrameworkModulePkg/Universal/DataHubDxe/DataHub.h index de2e3f3..7770c43 100644 --- a/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.h +++ b/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.h @@ -2,7 +2,7 @@ This code supports a the private implementation=20 of the Data Hub protocol =20 -Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.
This program and the accompanying materials =20 are licensed and made available under the terms and conditions of the BSD = License =20 which accompanies this distribution. The full text of the license may be = found at =20 @@ -21,8 +21,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER= EXPRESS OR IMPLIED. =20 #include =20 -#include - #include #include #include di= ff --git a/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHubDxe.inf b/In= telFrameworkModulePkg/Universal/DataHubDxe/DataHubDxe.inf index 834c3b3..0b93f71 100644 --- a/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHubDxe.inf +++ b/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHubDxe.inf @@ -21,7 +21,7 @@ # drivers to be aware of all reporting formats. # For more information, please ref http://www.intel.com/technology/framew= ork/ # -# Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.
+# Copyright (c) 2006 - 2016, Intel Corporation. All rights=20 +reserved.
# # This program and the accompanying materials # are licensed and made a= vailable under the terms and conditions of the BSD License @@ -70,10 +70,6 = @@ DebugLib =20 =20 -[Guids] - gZeroGuid ## SOMETIMES_CONSUMES ##= GUID - - [Protocols] gEfiDataHubProtocolGuid ## PRODUCES =20 -- 1.9.5.msysgit.0