From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mx.groups.io with SMTP id smtpd.web12.10674.1594885481587756541 for ; Thu, 16 Jul 2020 00:44:41 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.100, mailfrom: qi1.zhang@intel.com) IronPort-SDR: jHOl6veKgKLjcDsTzr44ASF2e3U65CSGRjPmmWRqwaFYABjCVG+XsOOhlmLcoL9QDPLkrDtlMF OQjwosvd8mYA== X-IronPort-AV: E=McAfee;i="6000,8403,9683"; a="214071688" X-IronPort-AV: E=Sophos;i="5.75,358,1589266800"; d="scan'208";a="214071688" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Jul 2020 00:44:41 -0700 IronPort-SDR: 68yA31ePKjCUmeiYyXRMne3uNedenlNysifb5p8qvY9QkNYRS88fTXp/y2VaRyazzJqksqCEUM WzyH5xrPxaJA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,358,1589266800"; d="scan'208";a="430407238" Received: from shwdesssddpdqi.ccr.corp.intel.com ([10.239.9.10]) by orsmga004.jf.intel.com with ESMTP; 16 Jul 2020 00:44:39 -0700 From: Qi Zhang To: devel@edk2.groups.io Cc: Jiewen Yao , Jian J Wang , Chao Zhang , Qi Zhang Subject: [PATCH v2 1/7] SecurityPkg/TcgPpi: Add TcgPpi header file. Date: Thu, 16 Jul 2020 15:44:23 +0800 Message-Id: <20200716074430.9675-2-qi1.zhang@intel.com> X-Mailer: git-send-email 2.26.2.windows.1 In-Reply-To: <20200716074430.9675-1-qi1.zhang@intel.com> References: <20200716074430.9675-1-qi1.zhang@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Jiewen Yao REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2841 Cc: Jiewen Yao Cc: Jian J Wang Cc: Chao Zhang Cc: Qi Zhang Signed-off-by: Jiewen Yao --- SecurityPkg/Include/Ppi/Tcg.h | 52 +++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 SecurityPkg/Include/Ppi/Tcg.h diff --git a/SecurityPkg/Include/Ppi/Tcg.h b/SecurityPkg/Include/Ppi/Tcg.h new file mode 100644 index 0000000000..2725a4ca71 --- /dev/null +++ b/SecurityPkg/Include/Ppi/Tcg.h @@ -0,0 +1,52 @@ +/** @file=0D + TCG PPI services.=0D +=0D +Copyright (c) 2020, Intel Corporation. All rights reserved.
=0D +SPDX-License-Identifier: BSD-2-Clause-Patent=0D +=0D +**/=0D +=0D +#ifndef _TCG_PPI_H_=0D +#define _TCG_PPI_H_=0D +=0D +#include =0D +=0D +typedef struct _EDKII_TCG_PPI EDKII_TCG_PPI;=0D +=0D +/**=0D + Tpm measure and log data, and extend the measurement result into a speci= fic PCR.=0D +=0D + @param[in] This Indicates the calling context=0D + @param[in] Flags Bitmap providing additional information=0D + @param[in] HashData Physical address of the start of the data = buffer=0D + to be hashed, extended, and logged.=0D + @param[in] HashDataLen The length, in bytes, of the buffer refere= nced by HashData.=0D + @param[in] NewEventHdr Pointer to a TCG_PCR_EVENT_HDR data struct= ure.=0D + @param[in] NewEventData Pointer to the new event data.=0D +=0D + @retval EFI_SUCCESS Operation completed successfully.=0D + @retval EFI_UNSUPPORTED TPM device not available.=0D + @retval EFI_OUT_OF_RESOURCES Out of memory.=0D + @retval EFI_DEVICE_ERROR The operation was unsuccessful.=0D +**/=0D +typedef=0D +EFI_STATUS=0D +(EFIAPI *EDKII_TCG_HASH_LOG_EXTEND_EVENT)(=0D + IN EDKII_TCG_PPI *This,=0D + IN UINT64 Flags,=0D + IN UINT8 *HashData,=0D + IN UINTN HashDataLen,=0D + IN TCG_PCR_EVENT_HDR *NewEventHdr,=0D + IN UINT8 *NewEventData=0D + );=0D +=0D +///=0D +/// The EFI_TCG Protocol abstracts TCG activity.=0D +///=0D +struct _EDKII_TCG_PPI {=0D + EDKII_TCG_HASH_LOG_EXTEND_EVENT HashLogExtendEvent;=0D +};=0D +=0D +extern EFI_GUID gEdkiiTcgPpiGuid;=0D +=0D +#endif=0D --=20 2.26.2.windows.1