From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (NAM10-MW2-obe.outbound.protection.outlook.com [40.107.94.54]) by mx.groups.io with SMTP id smtpd.web11.19485.1602864608059118209 for ; Fri, 16 Oct 2020 09:10:08 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amdcloud.onmicrosoft.com header.s=selector2-amdcloud-onmicrosoft-com header.b=ZvujNRBe; spf=none, err=SPF record not found (domain: amd.com, ip: 40.107.94.54, mailfrom: thomas.lendacky@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=K2I8/RZiSFUdlHEM47f7SC+U/809UARqz7cXmeyeOL4xeirAfpbgh5zp0Ak3dZta81yF6Q+0fXlae7i/G7sG8D0B4BMEEcMT+gQ9UWyplf96wyNRPCmDw+JX9rkJNDttiNL+K9O469oUKsjK4fYyRlmrI+/b5ef/QO+sI2IcqbQcRdlvPnGcrJxkFxmcqZKIDsm44rWVSTI4VcIsUzJDsF/gPpgxla1gf/ccs0qdIXZektu1CxO5njMTxQWNDWkbjZ6OvLzxX5L0metoQyncmywsroPAMBEPIh2OcHc9Rb+iANrevOEeOg4EZQ6aDBTcck8J+5bShnsc8/sfKaTo9g== 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-SenderADCheck; bh=OQjUCedu5tIfgyByRZFWWwAwp3XN99r0COQs+hL0fx4=; b=ayG1iFlx7U8oEBWdyT+GXDfuBTBsvrMlIf88GIzw6At9oo8O/ZfPzMKPTbFtjqGog8LqacZle0n79u+gDkgF2+uM/Sx3xjcNeA7eCwhOL4enJhUsjYEWRwr+Lqe1ZFDuhPvpjMfFc2MTby8bNhb3dyXDEkoOvl/Q2Y/SSFi3pXOgMTZdRmxldolzqMNN7ZbNiKrj1p7dB16qZQcqiWHk6lVmkPHksHJ7vDllmbo7QFdMNEKmJ89ZFa4MGIaOI7txDEpteAFAkpBod3jTghXpsVk6humXM2Fl6Qk5M4R+r4uRdrnzCYGjLf0tepEY1xUNbixC/rjFD2VeRl8kZN4Xjg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector2-amdcloud-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OQjUCedu5tIfgyByRZFWWwAwp3XN99r0COQs+hL0fx4=; b=ZvujNRBe1wN1IQ/DUxcn0Bkw9cdEUUW/R5D/wYr+mi6Hr9wqDoR1Tfp+jogJ7VGefMolHYcI2moJ/v2ZoxIHzOp35XNxscckBNaTbWPJabge/nIbeUDgsDb1KL/OyOK6uC2uD3GIqYGlSfU17SeXujjb9uKg8GRWb4CRwzBg9uU= Authentication-Results: edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=none action=none header.from=amd.com; Received: from DM5PR12MB1355.namprd12.prod.outlook.com (2603:10b6:3:6e::7) by DM6PR12MB4926.namprd12.prod.outlook.com (2603:10b6:5:1bb::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.20; Fri, 16 Oct 2020 16:10:07 +0000 Received: from DM5PR12MB1355.namprd12.prod.outlook.com ([fe80::4d88:9239:2419:7348]) by DM5PR12MB1355.namprd12.prod.outlook.com ([fe80::4d88:9239:2419:7348%2]) with mapi id 15.20.3455.030; Fri, 16 Oct 2020 16:10:07 +0000 From: "Lendacky, Thomas" To: devel@edk2.groups.io CC: Brijesh Singh , Jordan Justen , Laszlo Ersek , Ard Biesheuvel Subject: [PATCH v2 05/11] OvmfPkg/VmgExitLib: Set the SwScratch valid bit for IOIO events Date: Fri, 16 Oct 2020 11:09:11 -0500 Message-ID: <431562a3f8f57207a757b0c706fd77813f3e949f.1602864557.git.thomas.lendacky@amd.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: References: X-Originating-IP: [165.204.77.1] X-ClientProxiedBy: DM5PR11CA0009.namprd11.prod.outlook.com (2603:10b6:3:115::19) To DM5PR12MB1355.namprd12.prod.outlook.com (2603:10b6:3:6e::7) Return-Path: thomas.lendacky@amd.com MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from tlendack-t1.amd.com (165.204.77.1) by DM5PR11CA0009.namprd11.prod.outlook.com (2603:10b6:3:115::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3477.21 via Frontend Transport; Fri, 16 Oct 2020 16:10:06 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 4dc1b04e-45b5-445f-7868-08d871edf2da X-MS-TrafficTypeDiagnostic: DM6PR12MB4926: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5516; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: TWT+BP50vx3CF2KnVx7flMAb/Oz2eDsJq4EWxVDe/BtQtSWwVhjiK0MHsJC0luJwga1cMbDzkWwlKf958bokTuUsvoB8JWYVpjax0j1IuYuA1HYoYVqFbzyZ6pXBWTdenGx7qPycMTY1euDvQcKIPZO5n1PkEw+7hhhMT4OXc2NuGx3XX/dqwUNiEJKgf0y9cgsUCKt5D7x3s2iw/k6kH1KqmsF5JT9p8JRkms+M/Rtwu7tEVcZcan5NZysAeqyGq0xB78hvngjpHV7SdwAdTDWf7Fkw2/9OlsBVITki3uWeKOuAQz8yMrMKpNk3McYkPw2BIlWR4r0r5SCelSwQ5r2BH5XS8Sp227ISpU19PLaGER6F8jGgHZN4pzNcfk/Z+FFUv2/lqsu8r7KY1FLmHXZu0USncjqS9dmS+jKoFdLlFU67Ln/UIeZD9yoCQLpkvkS3GP4N3h4PWB4zZIL1Bg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM5PR12MB1355.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(6029001)(4636009)(39860400002)(136003)(396003)(376002)(366004)(346002)(7696005)(52116002)(66556008)(66476007)(86362001)(66946007)(36756003)(4326008)(2906002)(316002)(6666004)(54906003)(6486002)(34490700002)(5660300002)(6916009)(26005)(956004)(2616005)(16526019)(478600001)(8936002)(966005)(8676002)(186003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: 9sHbh6uEoOCWf43DxEGN7XmNvmQClylHjRPlw7dIqRmTQVt4Bwpj3c86dQqmVw+sH5NUlsdN39SmVxkGjsnzYH0gCSAuTau899GzrOy8PAv/Dcv/BEaQu06dMvc9sSUIrsiIs8TomGhV4mTHkP5LImz9GIi+pCBVYHLcLMpQpM+Djks0UlFLL9kyQekbpEm5+RUI8MXYvmVWlvOBnzXzKufXQ5RtjC02rvGoD6uER47bP5VzInCX3qLvD7SRY7v34tgeUv+j8Ct/8DfDN+I3xAmodRR8V9ciigCjZM9B/kgA5YPe/YzaBlhi47BY0bgSVTHF+R03Lw6uoTTn7X5rFu8wEUJCNbLxkPSpmHg9sjM8soalMBOkCuokYu8r+zOkNcMKrhaFNIbMA1Bza28q7emdSfLaAZip6xMkuceJ8uv7VlqpkxC6bBQw+OHK9Kjiafjgbg70nsvX6xxvkbT46l2YvynJJ17Gm5c4R380T1JUmtZAQEsyAFzv75fBsEqZfgJXsAiNux+o82RIyxts8SL0nxN6Z/IpAZejHNkUpCz2/Ceow0RrM5CtWjtmqDXTajbLNB6qMpIi9zZJbyj1+QD6bW5HGt8Di/cMre4eS+dDfN2AgK0vnSRsUaInZjCK7H1v621lPuK4XUKW2pkjoQ== X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4dc1b04e-45b5-445f-7868-08d871edf2da X-MS-Exchange-CrossTenant-AuthSource: DM5PR12MB1355.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Oct 2020 16:10:07.0526 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: /55QShNIjMf6AI2XruQu0Vdaj8injdzht2phuE27DerJiJFLzRoIFXu0rhH/Q+QK3xq7e4lVZ+kn+m15S4n0/A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB4926 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable From: Tom Lendacky BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3008 All fields that are set in the GHCB should have their associated bit in the GHCB ValidBitmap field set. Add support to set the bit for the scratch area field (SwScratch). Fixes: 0020157a9825e5f5784ff014044f11c0558c92fe Cc: Jordan Justen Cc: Laszlo Ersek Cc: Ard Biesheuvel Cc: Tom Lendacky Cc: Brijesh Singh Acked-by: Laszlo Ersek Signed-off-by: Tom Lendacky --- OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c | 1 + 1 file changed, 1 insertion(+) diff --git a/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c b/OvmfPkg/Librar= y/VmgExitLib/VmgExitVcHandler.c index 7d14341d592b..e5f14035b06f 100644 --- a/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c +++ b/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c @@ -1233,6 +1233,7 @@ IoioExit ( } =20 Ghcb->SaveArea.SwScratch =3D (UINT64) Ghcb->SharedBuffer; + VmgSetOffsetValid (Ghcb, GhcbSwScratch); Status =3D VmgExit (Ghcb, SVM_EXIT_IOIO_PROT, ExitInfo1, ExitInfo2); if (Status !=3D 0) { return Status; --=20 2.28.0