From: "Yao, Jiewen" <jiewen.yao@intel.com>
To: "Zhang, Chao B" <chao.b.zhang@intel.com>,
"Zeng, Star" <star.zeng@intel.com>,
"edk2-devel@lists.01.org" <edk2-devel@lists.01.org>
Subject: Re: [PATCH 2/3] MdePkg: VariableDxe: Use UEFI_VARIABLE_DATA
Date: Wed, 25 Jan 2017 02:18:02 +0000 [thread overview]
Message-ID: <74D8A39837DF1E4DA445A8C0B3885C503A8E522A@shsmsx102.ccr.corp.intel.com> (raw)
In-Reply-To: <FF72C7E4248F3C4E9BDF19D4918E90F2494F94F5@shsmsx102.ccr.corp.intel.com>
Thank you.
I also think this is a right way to go.
One observation I have is that we need use sizeof(TREE_BOOT_SERVICE_CAPABILITY_1_0) in Tcg2Dxe.
I think we can use OFFSET_OF(EFI_TCG2_BOOT_SERVICE_CAPABILITY , NumberOfPCRBanks) to remove TrEE reference in Tcg2.
Thank you
Yao Jiewen
> -----Original Message-----
> From: Zhang, Chao B
> Sent: Wednesday, January 25, 2017 10:13 AM
> To: Zeng, Star <star.zeng@intel.com>; edk2-devel@lists.01.org
> Cc: Yao, Jiewen <jiewen.yao@intel.com>
> Subject: RE: [edk2] [PATCH 2/3] MdePkg: VariableDxe: Use UEFI_VARIABLE_DATA
>
> Star:
> I agree. I will clean up other TrEEProtocol reference later on.
>
> -----Original Message-----
> From: Zeng, Star
> Sent: Tuesday, January 24, 2017 4:33 PM
> To: Zhang, Chao B <chao.b.zhang@intel.com>; edk2-devel@lists.01.org
> Cc: Yao, Jiewen <jiewen.yao@intel.com>; Zeng, Star <star.zeng@intel.com>
> Subject: RE: [edk2] [PATCH 2/3] MdePkg: VariableDxe: Use UEFI_VARIABLE_DATA
>
> Could we remove " #include <Protocol/TrEEProtocol.h>" in Measurement.c?
>
> Thanks,
> Star
> -----Original Message-----
> From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Zhang,
> Chao B
> Sent: Tuesday, January 24, 2017 3:58 PM
> To: edk2-devel@lists.01.org
> Cc: Yao, Jiewen <jiewen.yao@intel.com>; Zhang, Chao B
> <chao.b.zhang@intel.com>; Zeng, Star <star.zeng@intel.com>
> Subject: [edk2] [PATCH 2/3] MdePkg: VariableDxe: Use UEFI_VARIABLE_DATA
>
> Use UEFI_VARIABLE_DATA data structure according to TCG PC-Client PFP Spec
> 00.21.
> http://www.trustedcomputinggroup.org/wp-content/uploads/PC-ClientSpecific
> _Platform_Profile_for_TPM_2p0_Systems_v21.pdf
>
> Cc: Star Zeng <star.zeng@intel.com>
> Cc: Yao Jiewen <jiewen.yao@intel.com>
> Contributed-under: TianoCore Contribution Agreement 1.0
> Signed-off-by: Chao Zhang <chao.b.zhang@intel.com>
> ---
> MdeModulePkg/Universal/Variable/RuntimeDxe/Measurement.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/Measurement.c
> b/MdeModulePkg/Universal/Variable/RuntimeDxe/Measurement.c
> index 309521f..b9febac 100644
> --- a/MdeModulePkg/Universal/Variable/RuntimeDxe/Measurement.c
> +++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/Measurement.c
> @@ -96,7 +96,7 @@ MeasureVariable (
> {
> EFI_STATUS Status;
> UINTN VarNameLength;
> - EFI_VARIABLE_DATA_TREE *VarLog;
> + UEFI_VARIABLE_DATA *VarLog;
> UINT32 VarLogSize;
>
> ASSERT ((VarSize == 0 && VarData == NULL) || (VarSize != 0 && VarData !=
> NULL)); @@ -105,7 +105,7 @@ MeasureVariable (
> VarLogSize = (UINT32)(sizeof (*VarLog) + VarNameLength * sizeof (*VarName)
> + VarSize
> - sizeof (VarLog->UnicodeName) - sizeof
> (VarLog->VariableData));
>
> - VarLog = (EFI_VARIABLE_DATA_TREE *) AllocateZeroPool (VarLogSize);
> + VarLog = (UEFI_VARIABLE_DATA *) AllocateZeroPool (VarLogSize);
> if (VarLog == NULL) {
> return EFI_OUT_OF_RESOURCES;
> }
> --
> 1.9.5.msysgit.1
>
> _______________________________________________
> edk2-devel mailing list
> edk2-devel@lists.01.org
> https://lists.01.org/mailman/listinfo/edk2-devel
next prev parent reply other threads:[~2017-01-25 2:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20170124075732.27484-1-chao.b.zhang@intel.com>
2017-01-24 7:57 ` [PATCH 2/3] MdePkg: VariableDxe: Use UEFI_VARIABLE_DATA Zhang, Chao B
2017-01-24 8:32 ` Zeng, Star
2017-01-24 8:36 ` Zeng, Star
2017-01-25 2:12 ` Zhang, Chao B
2017-01-25 2:18 ` Yao, Jiewen [this message]
2017-01-24 7:57 ` [PATCH 3/3] SecurityPkg: Tcg2Dxe: " Zhang, Chao B
2017-01-24 8:21 ` [PATCH 1/3] MdePkg: UefiTcgPlatform.h: Add UEFI_VARIABLE_DATA Yao, Jiewen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=74D8A39837DF1E4DA445A8C0B3885C503A8E522A@shsmsx102.ccr.corp.intel.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox