From 3d97733f44ef03f309726dce8cf6102d7c86bd31 Mon Sep 17 00:00:00 2001 From: Min Xu Date: Tue, 19 Apr 2022 08:26:22 +0800 Subject: MdePkg: Add CC_GUEST_TYPE in ConfidentialComputingGuestAttr.h BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3902 The confidential computing guest type (GUEST_TYPE) was defined in OvmfPkg/Include/WorkArea.h. Now it is to be moved to MdePkg/Include/ConfidentialComputingGuestAttr.h and renamed as CC_GUEST_TYPE. There are 2 reasons for this change. 1. CC_GUEST_TYPE is a generic definition and will be used in CcProbeLib which is defined in MdePkg. 2. Based on the latest edk2 coding style: - First character should be upper case - Must contain lower case characters - No white space characters - Global variable name must start with a 'g' As the first step CC_GUEST_TYPE is defined in this patch. In the next patch GUEST_TYPE will be deleted. This is to make sure the bisect work correctly. Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Cc: James Bottomley Cc: Jiewen Yao Cc: Gerd Hoffmann Cc: Brijesh Singh Cc: Erdem Aktas Cc: Tom Lendacky Reviewed-by: Liming Gao Reviewed-by: Jiewen Yao Reviewed-by: Tom Lendacky Signed-off-by: Min Xu --- MdePkg/Include/ConfidentialComputingGuestAttr.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'MdePkg') diff --git a/MdePkg/Include/ConfidentialComputingGuestAttr.h b/MdePkg/Include/ConfidentialComputingGuestAttr.h index dd2541c..44e6df8 100644 --- a/MdePkg/Include/ConfidentialComputingGuestAttr.h +++ b/MdePkg/Include/ConfidentialComputingGuestAttr.h @@ -1,5 +1,5 @@ /** @file -Definitions for Confidential Computing Attribute +Definitions for Confidential Computing Guest Attributes Copyright (c) 2021 AMD Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent @@ -9,6 +9,15 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #ifndef CONFIDENTIAL_COMPUTING_GUEST_ATTR_H_ #define CONFIDENTIAL_COMPUTING_GUEST_ATTR_H_ +// +// Confidential computing guest type +// +typedef enum { + CcGuestTypeNonEncrypted = 0, + CcGuestTypeAmdSev, + CcGuestTypeIntelTdx, +} CC_GUEST_TYPE; + typedef enum { /* The guest is running with memory encryption disabled. */ CCAttrNotEncrypted = 0, -- cgit v1.1