public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Zhang, Chao B" <chao.b.zhang@intel.com>
To: edk2-devel@lists.01.org
Cc: Jiewen Yao <jiewen.yao@intel.com>, Chao B Zhang <chao.b.zhang@intel.com>
Subject: [PATCH 14/15] SecurityPkg/include: remove TrEE.
Date: Thu, 15 Mar 2018 15:35:36 +0800	[thread overview]
Message-ID: <20180315073537.16692-15-chao.b.zhang@intel.com> (raw)
In-Reply-To: <20180315073537.16692-1-chao.b.zhang@intel.com>

From: Jiewen Yao <jiewen.yao@intel.com>

TrEE is deprecated. We need use Tcg2.

Cc: Chao B Zhang <chao.b.zhang@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Jiewen Yao <jiewen.yao@intel.com>
---
 SecurityPkg/Include/Guid/TrEEConfigHii.h              |  25 ---
 SecurityPkg/Include/Guid/TrEEPhysicalPresenceData.h   |  67 --------
 SecurityPkg/Include/Library/TrEEPhysicalPresenceLib.h |  57 -------
 SecurityPkg/Include/Library/TrEEPpVendorLib.h         | 164 --------------------
 4 files changed, 313 deletions(-)

diff --git a/SecurityPkg/Include/Guid/TrEEConfigHii.h b/SecurityPkg/Include/Guid/TrEEConfigHii.h
deleted file mode 100644
index b5d1de746a..0000000000
--- a/SecurityPkg/Include/Guid/TrEEConfigHii.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/** @file
-  GUIDs used as HII FormSet and HII Package list GUID in TrEEConfig driver. 
-  
-Copyright (c) 2013, 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 that accompanies this distribution.  
-The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php.                                            
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#ifndef __TREE_CONFIG_HII_GUID_H__
-#define __TREE_CONFIG_HII_GUID_H__
-
-#define TREE_CONFIG_FORM_SET_GUID \
-  { \
-    0xc54b425f, 0xaa79, 0x48b4, { 0x98, 0x1f, 0x99, 0x8b, 0x3c, 0x4b, 0x64, 0x1c } \
-  }
-
-extern EFI_GUID gTrEEConfigFormSetGuid;
-
-#endif
diff --git a/SecurityPkg/Include/Guid/TrEEPhysicalPresenceData.h b/SecurityPkg/Include/Guid/TrEEPhysicalPresenceData.h
deleted file mode 100644
index 0e2f8d1096..0000000000
--- a/SecurityPkg/Include/Guid/TrEEPhysicalPresenceData.h
+++ /dev/null
@@ -1,67 +0,0 @@
-/** @file
-  Define the variable data structures used for TrEE physical presence.
-  The TPM2 request from firmware or OS is saved to variable. And it is
-  cleared after it is processed in the next boot cycle. The TPM2 response 
-  is saved to variable.
-
-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
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#ifndef __TREE_PHYSICAL_PRESENCE_DATA_GUID_H__
-#define __TREE_PHYSICAL_PRESENCE_DATA_GUID_H__
-
-#define EFI_TREE_PHYSICAL_PRESENCE_DATA_GUID \
-  { \
-    0xf24643c2, 0xc622, 0x494e, { 0x8a, 0xd, 0x46, 0x32, 0x57, 0x9c, 0x2d, 0x5b }\
-  }
-
-#define TREE_PHYSICAL_PRESENCE_VARIABLE  L"TrEEPhysicalPresence"
-
-typedef struct {
-  UINT8   PPRequest;      ///< Physical Presence request command.
-  UINT8   LastPPRequest;
-  UINT32  PPResponse;
-} EFI_TREE_PHYSICAL_PRESENCE;
-
-//
-// The definition bit of the flags
-//
-// BIT0 is reserved
-#define TREE_FLAG_NO_PPI_CLEAR                        BIT1
-// BIT2 is reserved
-#define TREE_FLAG_RESET_TRACK                         BIT3
-
-//
-// This variable is used to save TPM Management Flags and corresponding operations.
-// It should be protected from malicious software (e.g. Set it as read-only variable). 
-//
-#define TREE_PHYSICAL_PRESENCE_FLAGS_VARIABLE  L"TrEEPhysicalPresenceFlags"
-typedef struct {
-  UINT8   PPFlags;
-} EFI_TREE_PHYSICAL_PRESENCE_FLAGS;
-
-//
-// The definition of physical presence operation actions
-//
-#define TREE_PHYSICAL_PRESENCE_NO_ACTION                               0
-#define TREE_PHYSICAL_PRESENCE_CLEAR_CONTROL_CLEAR                     5
-#define TREE_PHYSICAL_PRESENCE_CLEAR_CONTROL_CLEAR_2                   14
-#define TREE_PHYSICAL_PRESENCE_SET_NO_PPI_CLEAR_FALSE                  17
-#define TREE_PHYSICAL_PRESENCE_SET_NO_PPI_CLEAR_TRUE                   18
-#define TREE_PHYSICAL_PRESENCE_CLEAR_CONTROL_CLEAR_3                   21
-#define TREE_PHYSICAL_PRESENCE_CLEAR_CONTROL_CLEAR_4                   22
-
-#define TREE_PHYSICAL_PRESENCE_NO_ACTION_MAX                           22
-
-extern EFI_GUID  gEfiTrEEPhysicalPresenceGuid;
-
-#endif
-
diff --git a/SecurityPkg/Include/Library/TrEEPhysicalPresenceLib.h b/SecurityPkg/Include/Library/TrEEPhysicalPresenceLib.h
deleted file mode 100644
index ba809b9cf9..0000000000
--- a/SecurityPkg/Include/Library/TrEEPhysicalPresenceLib.h
+++ /dev/null
@@ -1,57 +0,0 @@
-/** @file
-  This library is intended to be used by BDS modules.
-  This library will execute TPM2 request.
-
-Copyright (c) 2013 - 2016, 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 
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#ifndef _TREE_PHYSICAL_PRESENCE_LIB_H_
-#define _TREE_PHYSICAL_PRESENCE_LIB_H_
-
-#include <IndustryStandard/Tpm20.h>
-#include <Protocol/TrEEProtocol.h>
-
-/**
-  Check and execute the pending TPM request.
-
-  The TPM request may come from OS or BIOS. This API will display request information and wait 
-  for user confirmation if TPM request exists. The TPM request will be sent to TPM device after
-  the TPM request is confirmed, and one or more reset may be required to make TPM request to 
-  take effect.
-  
-  This API should be invoked after console in and console out are all ready as they are required
-  to display request information and get user input to confirm the request.  
-
-  @param  PlatformAuth                   platform auth value. NULL means no platform auth change.
-**/
-VOID
-EFIAPI
-TrEEPhysicalPresenceLibProcessRequest (
-  IN      TPM2B_AUTH                     *PlatformAuth  OPTIONAL
-  );
-
-/**
-  Check if the pending TPM request needs user input to confirm.
-
-  The TPM request may come from OS. This API will check if TPM request exists and need user
-  input to confirmation.
-  
-  @retval    TRUE        TPM needs input to confirm user physical presence.
-  @retval    FALSE       TPM doesn't need input to confirm user physical presence.
-
-**/
-BOOLEAN
-EFIAPI
-TrEEPhysicalPresenceLibNeedUserConfirm(
-  VOID
-  );
-
-#endif
diff --git a/SecurityPkg/Include/Library/TrEEPpVendorLib.h b/SecurityPkg/Include/Library/TrEEPpVendorLib.h
deleted file mode 100644
index f0dcfd9967..0000000000
--- a/SecurityPkg/Include/Library/TrEEPpVendorLib.h
+++ /dev/null
@@ -1,164 +0,0 @@
-/** @file
-  This library is to support Trusted Execution Environment (TrEE) ACPI Profile
-  >= 128 Vendor Specific PPI Operation.
-
-  The Vendor Specific PPI operation may change TPM state, BIOS TPM management
-  flags, and may need additional boot cycle.
-  
-  Caution: This function may receive untrusted input.
-
-Copyright (c) 2015 - 2016, 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 
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#ifndef _TREE_PP_VENDOR_LIB_H_
-#define _TREE_PP_VENDOR_LIB_H_
-
-#include <IndustryStandard/Tpm20.h>
-#include <Protocol/TrEEProtocol.h>
-
-//
-// The definition of physical presence operation actions
-//
-#define TREE_PHYSICAL_PRESENCE_VENDOR_SPECIFIC_OPERATION                         128
-
-//
-// The definition bit of the BIOS TPM Management Flags
-//
-// BIT0 is reserved
-#define TREE_BIOS_TPM_MANAGEMENT_FLAG_NO_PPI_CLEAR                        BIT1
-// BIT2 is reserved
-#define TREE_VENDOR_LIB_FLAG_RESET_TRACK                                  BIT3
-
-//
-// The definition for TPM Operation Response to OS Environment
-//
-#define TREE_PP_OPERATION_RESPONSE_SUCCESS              0x0
-#define TREE_PP_OPERATION_RESPONSE_USER_ABORT           0xFFFFFFF0
-#define TREE_PP_OPERATION_RESPONSE_BIOS_FAILURE         0xFFFFFFF1
-
-//
-// The return code for Submit TPM Request to Pre-OS Environment
-// and Submit TPM Request to Pre-OS Environment 2
-//
-#define TREE_PP_SUBMIT_REQUEST_TO_PREOS_SUCCESS                                  0
-#define TREE_PP_SUBMIT_REQUEST_TO_PREOS_NOT_IMPLEMENTED                          1
-#define TREE_PP_SUBMIT_REQUEST_TO_PREOS_GENERAL_FAILURE                          2
-#define TREE_PP_SUBMIT_REQUEST_TO_PREOS_BLOCKED_BY_BIOS_SETTINGS                 3
-
-//
-// The return code for Get User Confirmation Status for Operation
-//
-#define TREE_PP_GET_USER_CONFIRMATION_NOT_IMPLEMENTED                                 0
-#define TREE_PP_GET_USER_CONFIRMATION_BIOS_ONLY                                       1
-#define TREE_PP_GET_USER_CONFIRMATION_BLOCKED_BY_BIOS_CONFIGURATION                   2
-#define TREE_PP_GET_USER_CONFIRMATION_ALLOWED_AND_PPUSER_REQUIRED                     3
-#define TREE_PP_GET_USER_CONFIRMATION_ALLOWED_AND_PPUSER_NOT_REQUIRED                 4
-
-/**
-  Check and execute the requested physical presence command.
-
-  This API should be invoked in BIOS boot phase to process pending request.
-  
-  Caution: This function may receive untrusted input.
-  
-  If OperationRequest < 128, then ASSERT().
-
-  @param[in]      PlatformAuth     platform auth value. NULL means no platform auth change.
-  @param[in]      OperationRequest TPM physical presence operation request.
-  @param[in, out] ManagementFlags  BIOS TPM Management Flags.
-  @param[out]     ResetRequired    If reset is required to vendor settings in effect.
-                                   True, it indicates the reset is required.
-                                   False, it indicates the reset is not required.
-
-  @return TPM Operation Response to OS Environment.
-**/
-UINT32
-EFIAPI
-TrEEPpVendorLibExecutePendingRequest (
-  IN TPM2B_AUTH             *PlatformAuth,  OPTIONAL
-  IN UINT32                 OperationRequest,
-  IN OUT UINT32             *ManagementFlags,
-  OUT BOOLEAN               *ResetRequired
-  );
-
-/**
-  Check if there is a valid physical presence command request.
-
-  This API should be invoked in BIOS boot phase to process pending request.
-  
-  Caution: This function may receive untrusted input.
-
-  If OperationRequest < 128, then ASSERT().
-
-  @param[in]      OperationRequest TPM physical presence operation request.
-  @param[in]      ManagementFlags  BIOS TPM Management Flags.
-  @param[out]     RequestConfirmed If the physical presence operation command required user confirm from UI.
-                                   True, it indicates the command doesn't require user confirm.
-                                   False, it indicates the command need user confirm from UI.
-
-  @retval  TRUE        Physical Presence operation command is valid.
-  @retval  FALSE       Physical Presence operation command is invalid.
-**/
-BOOLEAN
-EFIAPI
-TrEEPpVendorLibHasValidRequest (
-  IN UINT32                 OperationRequest,
-  IN UINT32                 ManagementFlags,
-  OUT BOOLEAN               *RequestConfirmed
-  );
-
-/**
-  The callback for TPM vendor specific physical presence which is called for
-  Submit TPM Operation Request to Pre-OS Environment and
-  Submit TPM Operation Request to Pre-OS Environment 2.
-
-  This API should be invoked in OS runtime phase to interface with ACPI method.
-
-  Caution: This function may receive untrusted input.
-  
-  If OperationRequest < 128, then ASSERT().
-
-  @param[in]      OperationRequest TPM physical presence operation request.
-  @param[in]      ManagementFlags  BIOS TPM Management Flags.
-
-  @return Return Code for Submit TPM Operation Request to Pre-OS Environment and
-          Submit TPM Operation Request to Pre-OS Environment 2.
-**/
-UINT32
-EFIAPI
-TrEEPpVendorLibSubmitRequestToPreOSFunction (
-  IN UINT32                 OperationRequest,
-  IN UINT32                 ManagementFlags
-  );
-
-/**
-  The callback for TPM vendor specific physical presence which is called for
-  Get User Confirmation Status for Operation.
-
-  This API should be invoked in OS runtime phase to interface with ACPI method.
-
-  Caution: This function may receive untrusted input.
-  
-  If OperationRequest < 128, then ASSERT().
-
-  @param[in]      OperationRequest TPM physical presence operation request.
-  @param[in]      ManagementFlags  BIOS TPM Management Flags.
-
-  @return Return Code for Get User Confirmation Status for Operation.
-**/
-UINT32
-EFIAPI
-TrEEPpVendorLibGetUserConfirmationStatusFunction (
-  IN UINT32                 OperationRequest,
-  IN UINT32                 ManagementFlags
-  );
-
-#endif
-- 
2.16.2.windows.1



  parent reply	other threads:[~2018-03-15  7:29 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-15  7:35 [PATCH 00/15] Remove TrEE* Zhang, Chao B
2018-03-15  7:35 ` [PATCH 01/15] ShellPkg/UefiHandleParsingLib: remove TrEE reference Zhang, Chao B
2018-03-16  3:49   ` Ni, Ruiyu
2018-03-16  3:53     ` Ni, Ruiyu
2018-03-15  7:35 ` [PATCH 02/15] QuarkPlatformPkg: " Zhang, Chao B
2018-03-15 12:52   ` Steele, Kelly
2018-03-15  7:35 ` [PATCH 03/15] Vlv2TbltDevicePkg/Tcg2PhysicalPresenceLib: use Tcg2 instead of TrEE Zhang, Chao B
2018-03-16  3:21   ` Guo, Mang
2018-03-15  7:35 ` [PATCH 04/15] Vlv2TbltDevicePkg/Bds: " Zhang, Chao B
2018-03-16  3:22   ` Guo, Mang
2018-03-15  7:35 ` [PATCH 05/15] Vlv2TbltDevicePkg/dsc/fdf: " Zhang, Chao B
2018-03-16  3:22   ` Guo, Mang
2018-03-15  7:35 ` [PATCH 06/15] SecurityPkg/dsc: remove TrEE Zhang, Chao B
2018-03-15  7:35 ` [PATCH 07/15] SecurityPkg/TrEESmm: " Zhang, Chao B
2018-03-15  7:35 ` [PATCH 08/15] SecurityPkg/TrEEDxe: " Zhang, Chao B
2018-03-15  7:35 ` [PATCH 09/15] SecurityPkg/TrEEPei: " Zhang, Chao B
2018-03-15  7:35 ` [PATCH 10/15] SecurityPkg/TrEEConfig: " Zhang, Chao B
2018-03-15  7:35 ` [PATCH 11/15] SecurityPkg/Tpm2DeviceLibTrEE: " Zhang, Chao B
2018-03-15  7:35 ` [PATCH 12/15] SecurityPkg/TrEEPhysicalPresenceLib: " Zhang, Chao B
2018-03-15  7:35 ` [PATCH 13/15] SecurityPkg/TrEEVendorLib: " Zhang, Chao B
2018-03-15  7:35 ` Zhang, Chao B [this message]
2018-03-15  7:35 ` [PATCH 15/15] SecurityPkg/dec: " Zhang, Chao B
2018-03-15  8:39 ` [PATCH 00/15] Remove TrEE* Zhang, Chao B

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=20180315073537.16692-15-chao.b.zhang@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