From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (NAM12-BN8-obe.outbound.protection.outlook.com [40.107.237.87]) by mx.groups.io with SMTP id smtpd.web11.2839.1634962484522463939 for ; Fri, 22 Oct 2021 21:14:44 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amd.com header.s=selector1 header.b=np7SjFPC; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.237.87, mailfrom: brijesh.singh@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=BdrchCMcqHLWmgRMGlu+QkyR+kyFIxqhzKVLDKTVsryHTd3ccQDDsvHTGUhPpl9rWeX1SKzZfDZCD1YiYpUEoYisQCims81XpZTBCQhRxHyWO9uqxnXNj0D/S/WbvSI7wwZGjs5b2YiDoqCWd/1No3zhSfgU3WjwRAZjBGahauVqBmwPEsC60pKPLk5Xi+1TgxFzIpuGpIBE+2XahLz/D+vwM7+znmEGP4P007inOYIlPAmky22HYVKdEOPm8heMpEawP5futUOe6PYTlV5Bb/i+h2MRp57cuug6zztqzqxXSzeES9qI131U6N/NHkyAo4HufGZxVZ56O4mEoy2uwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=axPf5+xqp9XABvBj68lEjn3cO1Zlv4EutULsKiGvtPQ=; b=bEWwxAPLDPRKb3MFM3fUIpN31lmwNhHHRiOjO1C+G/Yy1WLLaHi0KaG5iiOGwkHm/EMXU1OqgI650ZIpKfOxlKiQ6AIj0ZnigXU0eDpwOEgO+SyZBLQwXSWySLrVw0xj3zFYIBu+X8N+tKJ3guBTPnfGi0wvrYUCBnm2ViSbkj+Oq53NntIkN/dOoa42+W7wAZhpgbLkdZmRUmkDxuS6TE28gfYqNWe1YuLIlJabqjlqXIuyjdP3noZHAFDGB9JpxzwJCZNRxK3b7rf9iHAQiTvpFZWDWrRHFi+edeXtFyPhSojhcADuDFnzzwNGAoVgbr9HUu5yTUr5SANSreZEGA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=edk2.groups.io smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=axPf5+xqp9XABvBj68lEjn3cO1Zlv4EutULsKiGvtPQ=; b=np7SjFPCymQXNwMORY7McC+VM7RENKFjNu3bDWfT8XvbFBDOAtBrXoLBG+buHjAH0jK0Yj64JnS8xs0s7GY/9tL59seS3Zq3ODgtXiW+G0xc5BR88i9EAg/2yff6HSWSycrvKtjZ74Fe4ayMVIlRlTGialKCJQ53hvtKxz4aSic= Received: from BN9PR03CA0639.namprd03.prod.outlook.com (2603:10b6:408:13b::14) by BYAPR12MB3016.namprd12.prod.outlook.com (2603:10b6:a03:dc::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4628.16; Sat, 23 Oct 2021 04:14:39 +0000 Received: from BN8NAM11FT037.eop-nam11.prod.protection.outlook.com (2603:10b6:408:13b:cafe::e) by BN9PR03CA0639.outlook.office365.com (2603:10b6:408:13b::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4628.18 via Frontend Transport; Sat, 23 Oct 2021 04:14:39 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; Received: from SATLEXMB04.amd.com (165.204.84.17) by BN8NAM11FT037.mail.protection.outlook.com (10.13.177.182) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.4628.16 via Frontend Transport; Sat, 23 Oct 2021 04:14:39 +0000 Received: from sbrijesh-desktop.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.15; Fri, 22 Oct 2021 23:14:36 -0500 From: "Brijesh Singh" To: CC: James Bottomley , Min Xu , "Jiewen Yao" , Tom Lendacky , "Jordan Justen" , Ard Biesheuvel , Erdem Aktas , "Michael Roth" , Gerd Hoffmann , Brijesh Singh , Michael Roth , Ray Ni , Rahul Kumar , Eric Dong Subject: [PATCH v11 23/32] UefiCpuPkg: add PcdGhcbHypervisorFeatures Date: Fri, 22 Oct 2021 23:13:40 -0500 Message-ID: <20211023041349.1263726-24-brijesh.singh@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211023041349.1263726-1-brijesh.singh@amd.com> References: <20211023041349.1263726-1-brijesh.singh@amd.com> MIME-Version: 1.0 Return-Path: brijesh.singh@amd.com X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 019bc22d-2a84-4c74-048a-08d995dba18e X-MS-TrafficTypeDiagnostic: BYAPR12MB3016: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8882; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: QaSdYlyVOEc5Yp/9H3PkchvqnL5+G6Fvkq6tAdF/x5pXLl5tsOyllojrv5vhUyQ7tOhT7L+79XCnhJMm1oj4NZberdZ1xk3tVbxoHDZNvZuVFx8Ku/0PLRq006+kNFgzg4s+lYR5o0GaqvuvHT93rDcOrOdr4/6vPlkNOkL7VWcV7YhH0FFqNbptMh+H8BQ694/BBWyGcWvg2WTuBIvyIuyXSRvXWyVE8/umQ2yqDOF019pC6EGCwHnK1klgDOntv4PYbsJO5cxZeuwYLpi52b/gpT5kRFztoiCFJrCWHojgZ06h+0Sq2wNbCu3sxL4qV1lLNTvUTLBfXgd9f7b3sami3+Ul/AoMnzABFdwPgp2J2NPUHcR5/r4KlD5o0u3js7fH/qV6LZUrJXS3uH/dTF7uH2KCkKt9nKBi/P9WdKMDhkq5IRolzM3qo2nnIsWnQWc+mcNpON3MhObcLY3gpo1jLfs0zHK0uhhG9YeReWetzywH7bDJP0Hh3m25xQRnD2YMROkpqnZu46UIw6FdKTKjFJpbvqSrVDe0o8K/e+vORO4oU9LqWlAIuvOgsNMfF0KVsiZalOndQPR5uFDnh2WUh+ShP10+M81+T2/qDX289RegimuFvUVheO8vs8UEJ0bOY1dBWudARmOpaivlgpMIyXcOofeTUNzgML+3Tk6MBywVWVfpl94cxXdp9f41C4blzRdAGKr7wCgyItd0sSd8IKlDeaEfPEuPqyTIKXpRCdOOhr5JNNOtog+xzuS2zetMUG7YaSenbn5HCIzjDdHaT8nEdEqH61spezBOf/BkQQ3D9tOc6HK/3AZUQLSxcbbZL7LeGLVS+PT162Kl7Ora1eZ79nehAUsBqR8LbMM= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(4636009)(46966006)(36840700001)(7696005)(966005)(54906003)(7416002)(70206006)(70586007)(8936002)(82310400003)(26005)(4326008)(508600001)(81166007)(16526019)(47076005)(426003)(8676002)(6666004)(36860700001)(2616005)(6916009)(5660300002)(2906002)(86362001)(44832011)(356005)(186003)(1076003)(336012)(36756003)(316002)(156123004)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Oct 2021 04:14:39.0011 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 019bc22d-2a84-4c74-048a-08d995dba18e X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT037.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB3016 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3275 Version 2 of the GHCB specification added a new VMGEXIT that the guest could use for querying the hypervisor features. One of the immediate users for it will be an AP creation code. When SEV-SNP is enabled, the guest can use the newly added AP_CREATE VMGEXIT to create the APs. The MpInitLib will check the hypervisor feature, and if AP_CREATE is available, it will use it. See GHCB spec version 2 for more details on the VMGEXIT. 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: Brijesh Singh --- UefiCpuPkg/UefiCpuPkg.dec | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/UefiCpuPkg/UefiCpuPkg.dec b/UefiCpuPkg/UefiCpuPkg.dec index 62acb291f309..7de66fde674c 100644 --- a/UefiCpuPkg/UefiCpuPkg.dec +++ b/UefiCpuPkg/UefiCpuPkg.dec @@ -396,5 +396,10 @@ [PcdsDynamic, PcdsDynamicEx] # @Prompt SEV-ES Status gUefiCpuPkgTokenSpaceGuid.PcdSevEsIsEnabled|FALSE|BOOLEAN|0x60000016 =20 + ## This dynamic PCD contains the hypervisor features value obtained thro= ugh the GHCB HYPERVISOR + # features VMGEXIT defined in the version 2 of GHCB spec. + # @Prompt GHCB Hypervisor Features + gUefiCpuPkgTokenSpaceGuid.PcdGhcbHypervisorFeatures|0x0|UINT64|0x6000001= 8 + [UserExtensions.TianoCore."ExtraFiles"] UefiCpuPkgExtra.uni --=20 2.25.1