Revision: 17843
http://sourceforge.net/p/edk2/code/17843
Author: hwu1225
Date: 2015-07-07 03:03:49 +0000 (Tue, 07 Jul 2015)
Log Message:
-----------
SecurityPkg: Remove mTrEEZeroGuid definition in DxeTpm2MeasureBootLib
MdeModulePkg has defined gZeroGuid in 'Guid/ZeroGuid.h', therefore, the
mTrEEZeroGuid defined in DxeTpm2MeasureBootLib is redundant.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Hao Wu <[email protected]>
Reviewed-by: Liming Gao <[email protected]>
Reviewed-by: Jaben Carsey <[email protected]>
Modified Paths:
--------------
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.c
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.inf
Modified:
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.c
===================================================================
---
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.c
2015-07-07 03:03:21 UTC (rev 17842)
+++
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.c
2015-07-07 03:03:49 UTC (rev 17843)
@@ -35,6 +35,7 @@
#include <Protocol/FirmwareVolumeBlock.h>
#include <Guid/MeasuredFvHob.h>
+#include <Guid/ZeroGuid.h>
#include <Library/BaseLib.h>
#include <Library/DebugLib.h>
@@ -51,7 +52,6 @@
// Flag to check GPT partition. It only need be measured once.
//
BOOLEAN mTrEEMeasureGptTableFlag = FALSE;
-EFI_GUID mTrEEZeroGuid = {0, 0, 0, {0, 0, 0, 0, 0, 0,
0, 0}};
UINTN mTrEEMeasureGptCount = 0;
VOID *mTrEEFileBuffer;
UINTN mTrEEImageSize;
@@ -201,7 +201,7 @@
PartitionEntry = (EFI_PARTITION_ENTRY *)EntryPtr;
NumberOfPartition = 0;
for (Index = 0; Index < PrimaryHeader->NumberOfPartitionEntries; Index++) {
- if (!CompareGuid (&PartitionEntry->PartitionTypeGUID, &mTrEEZeroGuid)) {
+ if (!CompareGuid (&PartitionEntry->PartitionTypeGUID, &gZeroGuid)) {
NumberOfPartition++;
}
PartitionEntry = (EFI_PARTITION_ENTRY *)((UINT8 *)PartitionEntry +
PrimaryHeader->SizeOfPartitionEntry);
@@ -237,7 +237,7 @@
PartitionEntry = (EFI_PARTITION_ENTRY*)EntryPtr;
NumberOfPartition = 0;
for (Index = 0; Index < PrimaryHeader->NumberOfPartitionEntries; Index++) {
- if (!CompareGuid (&PartitionEntry->PartitionTypeGUID, &mTrEEZeroGuid)) {
+ if (!CompareGuid (&PartitionEntry->PartitionTypeGUID, &gZeroGuid)) {
CopyMem (
(UINT8 *)&GptData->Partitions + NumberOfPartition *
PrimaryHeader->SizeOfPartitionEntry,
(UINT8 *)PartitionEntry,
Modified:
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.inf
===================================================================
---
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.inf
2015-07-07 03:03:21 UTC (rev 17842)
+++
trunk/edk2/SecurityPkg/Library/DxeTpm2MeasureBootLib/DxeTpm2MeasureBootLib.inf
2015-07-07 03:03:49 UTC (rev 17843)
@@ -9,7 +9,7 @@
# This external input must be validated carefully to avoid security issues
such
# as buffer overflow or integer overflow.
#
-# Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved.<BR>
+# Copyright (c) 2013 - 2015, Intel Corporation. All rights reserved.<BR>
# 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
@@ -58,6 +58,7 @@
[Guids]
gMeasuredFvHobGuid ## SOMETIMES_CONSUMES ## HOB
+ gZeroGuid ## SOMETIMES_CONSUMES ## GUID
[Protocols]
gEfiTrEEProtocolGuid ## SOMETIMES_CONSUMES
------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits