From nobody Mon Feb 9 17:25:25 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+85982+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85982+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1642901932; cv=none; d=zohomail.com; s=zohoarc; b=a2rfkQp+FfYyiaDrmSc6jDh0sWHqXxOksxgfLmFPYtduVwdagwoauh1M5y/r+58iVRFfyRaWRU3CYNYPhcZIifX+0iFY8LBXHYi5utt1zOLgUfDRPO1IGjyzbAOVIZJ4juIlcS8+uYLv8boF2Flig9ChTel5DZlwgKCAeFCYfT4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1642901932; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To; bh=b7di8pI9k4ZLDVyUmVJSns/mZVu0JiAnw0VaySKZ0jg=; b=Y3oQOtwKfsqeyKEZ6ICtN/rj2uCs2rxdUMG0Tr4M7NPW2jIT+flD8o72rbbxyyjRMx1zyUpumVmgPYYRqcRbV3Xg2/SoqRMfbmfbbeTcOTZjQbjslZHK26+LWlA3K2uqlLMNsr5UjBFwFfsqP+OI4DE0hN5pTvvRxhqNyI/r908= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+85982+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1642901932497901.0660704802523; Sat, 22 Jan 2022 17:38:52 -0800 (PST) Return-Path: X-Received: by 127.0.0.2 with SMTP id zZmJYY1788612xEnrhA9i3DN; Sat, 22 Jan 2022 17:38:52 -0800 X-Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mx.groups.io with SMTP id smtpd.web12.4573.1642901931649293959 for ; Sat, 22 Jan 2022 17:38:51 -0800 X-IronPort-AV: E=McAfee;i="6200,9189,10235"; a="244685988" X-IronPort-AV: E=Sophos;i="5.88,309,1635231600"; d="scan'208";a="244685988" X-Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Jan 2022 17:38:50 -0800 X-IronPort-AV: E=Sophos;i="5.88,309,1635231600"; d="scan'208";a="695033148" X-Received: from mxu9-mobl1.ccr.corp.intel.com ([10.255.30.84]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Jan 2022 17:38:47 -0800 From: "Min Xu" To: devel@edk2.groups.io Cc: Min Xu , Michael Roth , Ray Ni , Rahul Kumar , Eric Dong , James Bottomley , Jiewen Yao , Tom Lendacky , Jordan Justen , Ard Biesheuvel , Erdem Aktas , Gerd Hoffmann Subject: [edk2-devel] [PATCH V5 12/33] MdePkg: Add macro to check SEV / TDX guest Date: Sun, 23 Jan 2022 09:36:43 +0800 Message-Id: In-Reply-To: References: MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,min.m.xu@intel.com X-Gm-Message-State: qYiB3rCyY7jktItSvvT2x38Hx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1642901932; bh=lHQ3hefy0a0YM3U2cmWYD6O1RaNxOhSKpuR7PIkjr4Q=; h=Cc:Date:From:Reply-To:Subject:To; b=S27qjU+yRhGFTk1GleCLka0/dMqzBlCFssn4RQi1cXWOlThAtASAkcwcIqOh/xEaXuR ZpaUVJ3tbRZ/10TnHv3PYNXy70T4aNLx4IOEIdJMkU2cHTQHZxTBHTISFxjPhPRqUN7nS ZbUewXFtgC+AtTbqPIYs6DJkhLlTPb1TiAM= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1642901933474100002 Content-Type: text/plain; charset="utf-8" RFC: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3429 Add macros CC_GUEST_IS_SEV / CC_GUEST_IS_TDX to check SEV / TDX guest. Cc: Michael Roth Cc: Ray Ni Cc: Rahul Kumar Cc: Eric Dong Cc: James Bottomley Cc: Min Xu Cc: Jiewen Yao Cc: Tom Lendacky Cc: Jordan Justen Cc: Ard Biesheuvel Cc: Erdem Aktas Cc: Gerd Hoffmann Acked-by: Gerd Hoffmann Signed-off-by: Min Xu --- MdePkg/Include/ConfidentialComputingGuestAttr.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/MdePkg/Include/ConfidentialComputingGuestAttr.h b/MdePkg/Inclu= de/ConfidentialComputingGuestAttr.h index 6a1301801519..dd2541c6dcdf 100644 --- a/MdePkg/Include/ConfidentialComputingGuestAttr.h +++ b/MdePkg/Include/ConfidentialComputingGuestAttr.h @@ -22,4 +22,7 @@ typedef enum { CCAttrIntelTdx =3D 0x200, } CONFIDENTIAL_COMPUTING_GUEST_ATTR; =20 +#define CC_GUEST_IS_TDX(x) ((x) =3D=3D CCAttrIntelTdx) +#define CC_GUEST_IS_SEV(x) ((x) =3D=3D CCAttrAmdSev || (x) =3D=3D CCAttrA= mdSevEs || (x) =3D=3D CCAttrAmdSevSnp) + #endif --=20 2.29.2.windows.2 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#85982): https://edk2.groups.io/g/devel/message/85982 Mute This Topic: https://groups.io/mt/88617523/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-