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.51]) by mx.groups.io with SMTP id smtpd.web08.9604.1619184289056982387 for ; Fri, 23 Apr 2021 06:24:49 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@amd.com header.s=selector1 header.b=yjG8lDvT; 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.94.51, mailfrom: thomas.lendacky@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=OUdEaO0iZL/deLHBIK9A15gw5X5y8X83HJtfLH1UEolMEDdam1uag/FoUPf6MlI9yFlJHqHU6T/g3EoE1sv1LXrxhi8xQemvso0mg+YjGX6PVlG/q2BopgUHK71EZkelpPyFV3vA+H8yQCmBAfUJHRvJABKF90rD0FzZaxyGXvTxd0EU8MQ14qOFPlyB9eR73bQjmvU0wcayYRfgAKJKpgduwdAy10QM0zmbhAx9+jrBYLX6OWAPrOSDk9QvrQiQvNqrjiawJ3xJjLCXYVUzURaCZ70NeUEOP1r9GVAEXHEk/eN8lLx7xG355x25/87EbXZ5LNlc/nTyVWSKOdOyEg== 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=fY51dVsZfQw0rtuIxXzmMAzSpadBGsC4hSjI0lZ34ds=; b=RVhciDmB9qjlfQGBYrFvQzVs/0K1oS9fGPUoAJVnwvQv1zaLZYwtj46SF9tk1XHUGikc0ggJqetePTXUt+rQwHA135+agvqn9EqZAJXd9wrcvoudorLsrf2xlqtYPYqf2tFTRucoI6S4Q2sG0pCTPKNIA0QmywyIeHRFBYzOQwJ0b1PRdAtf6uMwlYBH2Pjn7Bk7vOJBTYfGlZicCaN/otMoZ4LevUnCytIS2UsbF2b2FywSO+wKQKUE5Fs/rLxSu8de2eUvzJby9V0mFt/MKGgnym1TAAUPtNLWhJbEgFlBzE5F6K6OrErGF/cUzjGSV7y9mwkFDUsK+HpzUc940w== 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=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fY51dVsZfQw0rtuIxXzmMAzSpadBGsC4hSjI0lZ34ds=; b=yjG8lDvTgNmco7Tsx2+DsfYph2RMyA1YR2fDHeCd8xAxgNVCd6OTGbEIHf84wvWsTdTxsBkQc4A9BUxsyiqxLPkQdVx6oTomZeFyMBqBRGUc/q6QqBVxzwpYDnsdP+o6L0sCIV+QjFd4eIp9IE7c3OZDgKem+6jdcZ3qSck4xqk= Authentication-Results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=amd.com; Received: from DM5PR12MB1355.namprd12.prod.outlook.com (2603:10b6:3:6e::7) by DM6PR12MB2795.namprd12.prod.outlook.com (2603:10b6:5:41::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4042.21; Fri, 23 Apr 2021 13:24:47 +0000 Received: from DM5PR12MB1355.namprd12.prod.outlook.com ([fe80::b914:4704:ad6f:aba9]) by DM5PR12MB1355.namprd12.prod.outlook.com ([fe80::b914:4704:ad6f:aba9%12]) with mapi id 15.20.4065.023; Fri, 23 Apr 2021 13:24:47 +0000 Subject: Re: [edk2-devel] [PATCH 2/3] OvmfPkg/VmgExitLib: Add support for new MMIO MOV opcodes To: Laszlo Ersek , devel@edk2.groups.io Cc: Joerg Roedel , Borislav Petkov , Ard Biesheuvel , Jordan Justen , Brijesh Singh , James Bottomley , Jiewen Yao , Min Xu References: <79ed645c089ffab10716cdb8813f191f6e0afcfb.1618959281.git.thomas.lendacky@amd.com> <5d4e5bdd-65ea-7594-3b51-e33284fe990f@amd.com> From: "Lendacky, Thomas" Message-ID: Date: Fri, 23 Apr 2021 08:24:44 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 In-Reply-To: X-Originating-IP: [67.79.209.213] X-ClientProxiedBy: SA0PR11CA0007.namprd11.prod.outlook.com (2603:10b6:806:d3::12) 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 office-linux.texastahm.com (67.79.209.213) by SA0PR11CA0007.namprd11.prod.outlook.com (2603:10b6:806:d3::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4065.21 via Frontend Transport; Fri, 23 Apr 2021 13:24:46 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 43486399-db18-4cef-8d05-08d9065b2a1c X-MS-TrafficTypeDiagnostic: DM6PR12MB2795: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:10000; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: TyfonSZJYODMi9RFGNzHLyppmMok5iZlEWA2L++B59d0qBRKsDsOxsYBmeir6SG9M2ANd1AQgfFh2SjohQFGcuMqoD4Pix3MHDoZ6uvMGY+x7J0t65+O/ErFUfr0fw/2nKtnoPAB5SkfNFrEoUrWtVj7igmjx8pP2wBU9xDKIrpXNVkjmcxOIpYj9Rr9eXWtvssLldqfhCJU7C7J/bftGjHjZ1eLDzAJY+tiKkpHjOzdb9rjCFH40ssfD0lt3S/G03SrQm1gVN0DGiCx3uSZgSDvgavBN/JD1EOm3wU+aprEAaya7g3A8JeDrV3srP6olk2AGr9IEVy898BhwG8NcpaOObhhsFroA4O3gYRmas7+QLMvF8rtvGeV8p1riVqGelt4+9lxQUywcK37ByRd5Mu3IuUEvjBLlJpYDyhdeoVAxIcLRSPMNam0aV8bzLTPbXpAU6IPlKe5zVKh2vTZuQniCaSlRaECZ2OFVgAEae1hhtF1nu62cqZMjG4sIHMH5BP98uaDL9G0DKJ6IyEBnAZnPew6DyfUk/wSFoOURp1FR6J4Y5B1H8FzFmURDXg4It88MuraiRFxpmbiodFaXFHaAiecZNzRyONYkMj0Oz07OtCwcTOSKcHjwZUZNRp6QRroilbTsYOmLP2dj8SOvM/X7S/RbYVMuPFhoU8NxDJQwuOAS8C0cw3cVnvW4JVJZGm9b1fEsOiTBNfTepA9r6qZyYjZ0h+8G57mTUEU2YX9q4hiugH/W0wNvewnFyY9k5PuyVauAJbrq6om7CMGXg== 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:(4636009)(396003)(346002)(39860400002)(366004)(136003)(376002)(54906003)(38100700002)(2906002)(53546011)(6506007)(8936002)(31686004)(478600001)(5660300002)(8676002)(956004)(2616005)(36756003)(6512007)(186003)(16526019)(66946007)(6486002)(4326008)(26005)(316002)(66556008)(45080400002)(31696002)(966005)(83380400001)(66476007)(86362001)(43740500002)(45980500001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: =?utf-8?B?alkzWGg0U25mUXNWc2lwTU5pM0pzSVI4TmFzdGdBWEN5NDc2MktMRnFFOHd6?= =?utf-8?B?ZDRmUDVLakQ3SFJBZ2MwL2NXbysyM0RHdDk1TGVQSzRxdGlrL25kZDFyRHdv?= =?utf-8?B?Q0pUK0JVM0h3SG5JY1E5UCtzOGVmTVBhTkxsOHZBYU5FejFoeWtORjRhNUdo?= =?utf-8?B?UFZrNTB3SkQ4SlA4bnRiV0FiVmFwMmVJL3dFSExGditzQ2ZJZHEvZ2tpbTRy?= =?utf-8?B?VzBQam1OS3dqSUF4Z2o4Qzk1Tk5QLzVlVVJzTnhwdnVhWXIxanR6bEx3SW9R?= =?utf-8?B?clByU3lYQUVUT2NwVmlhR05ZYzVyZGZMZlIwM3hWYWQrV3ZiNHhvU1l3SjIz?= =?utf-8?B?dkk0VzJIc3c4VWl0ZkR2aW9MU1lZditYdFZLSHp6dGpMMEpBVmtWN3FtdWVn?= =?utf-8?B?WlFVanlkcDFnZzJiZjFwQi9qc0RTS1JiTlVGNXZBc2pXeW0rTjBpb2hXbXps?= =?utf-8?B?WmIvYVF6LzFlTElzMzExOEZzaVpsQ0hTelVSa3czQWUwSUZnQ2o2UDU3cVAy?= =?utf-8?B?VUMrUWFCNnNlZFRZZzNQK0p1OE9qUW4zaXZMaW0zeVVFVEdyM2FWSHQyT1do?= =?utf-8?B?NStBbGtHT0svZEVuRFRTUlROcllTbEJrUm5IRnNoVGtySkFDVGlsbk03bENj?= =?utf-8?B?UjcrajN0TkZwQTM2Z056S0JTRER4TWR3a2tkTjh1WmpQMTQxQ1RnQndud3Fq?= =?utf-8?B?b0FCc3J3dDZGeHAxRzhGTnkvR3hTR2Y5V2s1ck9zS21LTlZVSGdRYXVlSGRG?= =?utf-8?B?UXJjekdNRHphNk5hcTNML1MyV0hkaEUxby9BRjBCbTEyc2lvbkx4OEJqYS9U?= =?utf-8?B?bkVFelJ3N1h4T1FmM01ZdTI4OTN0LzBWbk5OZDR1QjRKN2I2TEhoTkRhdkl0?= =?utf-8?B?SkNpcUY1VnBKaEZIZEtpODN5NHRzU2VUdllzQjhXbVI3aFZFYVNJY0FwWENV?= =?utf-8?B?dC9EQVZiRFZKQTlRVjI2UWhJSE9zTTh0cWhpSlBjVkxURnQwQTZWOXpyOWFp?= =?utf-8?B?ZWZYalFVRXh6Tmx2Sm9SRVJ1M1FaMDQzOVA5Mks5L3dyQU83VXRRd0JGbmov?= =?utf-8?B?UHAwMmhuMVRsN0RYRGhrckxFZTAvUkM5aFJCV1BnZHhESFNaTlFBVmNRbEJD?= =?utf-8?B?elVueGlTWXVtSURFcXd6RXJaK3ZUZ1pWNnU1RmorSVRnVXozdld2YldhZDU2?= =?utf-8?B?K3puQjhoMnRnaGFhVjFQRGZZcGdRczRZOTV2d2JhR1lFSnEwblM0eVpQREhW?= =?utf-8?B?SWMyeVVMcVZ2ZUVxZ0RPVEwxT2JPSGRRNUk5TEpVWHo2MWtzSDR3Y3c3ZGFh?= =?utf-8?B?S1pUQzNEeE82ZHVGZ2hNT3luL3dySDhETFh4OFVDNGdzMEtSY0dZQzE1bXM1?= =?utf-8?B?MlBVWnEvSU9oTHRmYVYzRFNWRys1amE2dngwUUVjOWlEZXl5S0FpSkwxYVYx?= =?utf-8?B?VXRkdUloN2hlc2tlUExvNUltcmEzMTJvMGdQbkNFWTg2RnFMUDBWRTFiVW5K?= =?utf-8?B?VTUxVlZleE5oeG5saU93UUhXbTlJRVBKN09UN0FtZVdKQnVHQzBjNThoV0F0?= =?utf-8?B?Sk1JY1MwRVdTM0NMeHBZb3RVUldvclJVQXQ3cVFxNmNvS2ZidHdPMTJKaTBh?= =?utf-8?B?emZTT1ZiZzlTS0plc0V6dlBnMThkNitrNlNiSllTN1VkL3ZJc29PSHRkemJK?= =?utf-8?B?a2dmSWhQUE94c2NKOStjeHRoemRaL1N3V3ZpWktTMTNBL1dkL1V5T05qUzhO?= =?utf-8?Q?tlJdZEjuZx+SwEq3bEDuri1Nk7Rdy7BizKvdJa0?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 43486399-db18-4cef-8d05-08d9065b2a1c X-MS-Exchange-CrossTenant-AuthSource: DM5PR12MB1355.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Apr 2021 13:24:47.0189 (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: ooIbe+PqA0Y2glLrhgRPaEwQ4mg8fIEtgN8Z4bU97v3pJmE8jH+JsiExlMRccugEhzK+eBBQ2uCboDkx7IHIaw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB2795 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 4/23/21 4:10 AM, Laszlo Ersek wrote: > On 04/22/21 17:42, Tom Lendacky wrote: >> On 4/22/21 9:15 AM, Tom Lendacky wrote: >>> On 4/22/21 12:50 AM, Laszlo Ersek via groups.io wrote: >>>> On 04/21/21 00:54, Lendacky, Thomas wrote: >>>>> From: Tom Lendacky >>>>> >>>>> BZ: https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugzilla.tianocore.org%2Fshow_bug.cgi%3Fid%3D3345&data=04%7C01%7Cthomas.lendacky%40amd.com%7Ca0ff778cdbb146a6186508d90637ba60%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637547658699539157%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=vMmmGGXXT8MtM4WOB4gkwtkr0cwwkx98LoOXYg6fclQ%3D&reserved=0 >>>>> >>>>> Enabling TPM support results in guest termination of an SEV-ES guest >>>>> because it uses MMIO opcodes that are not currently supported. >>>>> >>>>> Add support for the new MMIO opcodes (0xA0 - 0xA3), MOV instructions which >>>>> use a memory offset directly encoded in the instruction. Also, add a DEBUG >>>>> statement to identify an unsupported MMIO opcode being used. >>>>> >>>>> Fixes: c45f678a1ea2080344e125dc55b14e4b9f98483d >>>>> Cc: Laszlo Ersek >>>>> Cc: Ard Biesheuvel >>>>> Cc: Jordan Justen >>>>> Cc: Brijesh Singh >>>>> Cc: James Bottomley >>>>> Cc: Jiewen Yao >>>>> Cc: Min Xu >>>>> Signed-off-by: Tom Lendacky >>>>> --- >>>>> OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c | 99 +++++++++++++++++++ >>>>> 1 file changed, 99 insertions(+) >>>>> >>>>> diff --git a/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c b/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c >>>>> index 273f36499988..f9660b757d8e 100644 >>>>> --- a/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c >>>>> +++ b/OvmfPkg/Library/VmgExitLib/VmgExitVcHandler.c >>>>> @@ -678,6 +678,7 @@ MmioExit ( >>>>> UINTN Bytes; >>>>> UINT64 *Register; >>>>> UINT8 OpCode, SignByte; >>>>> + UINTN Address; >>>>> >>>>> Bytes = 0; >>>>> >>>>> @@ -727,6 +728,51 @@ MmioExit ( >>>>> } >>>>> break; >>>>> >>>>> + // >>>>> + // MMIO write (MOV moffsetX, aX) >>>>> + // >>>>> + case 0xA2: >>>>> + Bytes = 1; >>>>> + // >>>>> + // fall through >>>>> + // >>>>> + case 0xA3: >>>>> + Bytes = ((Bytes != 0) ? Bytes : >>>>> + (InstructionData->DataSize == Size16Bits) ? 2 : >>>>> + (InstructionData->DataSize == Size32Bits) ? 4 : >>>>> + (InstructionData->DataSize == Size64Bits) ? 8 : >>>>> + 0); >>>>> + >>>>> + InstructionData->ImmediateSize = (UINTN) (1 << InstructionData->AddrSize); >>>>> + InstructionData->End += (UINTN) (1 << InstructionData->AddrSize); >>>>> + >>>>> + if (InstructionData->AddrSize == Size8Bits) { >>>>> + Address = *(UINT8 *) InstructionData->Immediate; >>>>> + } else if (InstructionData->AddrSize == Size16Bits) { >>>>> + Address = *(UINT16 *) InstructionData->Immediate; >>>>> + } else if (InstructionData->AddrSize == Size32Bits) { >>>>> + Address = *(UINT32 *) InstructionData->Immediate; >>>>> + } else { >>>>> + Address = *(UINTN *) InstructionData->Immediate; >>>>> + } >>>> >>>> (1) Can we simplify this as follows? >>>> >>>> InstructionData->ImmediateSize = 1 << InstructionData->AddrSize; >>>> InstructionData->End += InstructionData->ImmediateSize; >>>> Address = 0; >>>> CopyMem (&Address, InstructionData->Immediate, >>>> InstructionData->ImmediateSize); >>> >>> Yup, that can be done. >> >> "Address" is a type UINTN, but since this is X64 only code, an 8-byte copy >> isn't an issue. Should I add a comment about that above the setting of >> "Address"? Or should I convert "Address" to a UINT64 - although >> ValidateMmioMemory expects a UINTN... Thoughts? > > Yes, I had the exact same thought process :) > > The comment looks good, but how about expressing it as a STATIC_ASSERT, > with sizeof (UINTN) and sizeof (UINT64) being equal? (Alternatively, > about MAX_UINT64 being equal to MAX_UINTN.) I like the STATIC_ASSERT idea, I'll do that. Thanks, Tom > > If you find that too verbose, a comment is good enough too, of course. > > Thanks! > Laszlo > >> >> Thanks, >> Tom >> >>> >>>> >>>>> + >>>>> + Status = ValidateMmioMemory (Ghcb, Address, Bytes); >>>>> + if (Status != 0) { >>>>> + return Status; >>>>> + } >>>>> + >>>>> + ExitInfo1 = Address; >>>>> + ExitInfo2 = Bytes; >>>>> + CopyMem (Ghcb->SharedBuffer, &Regs->Rax, Bytes); >>>>> + >>>>> + Ghcb->SaveArea.SwScratch = (UINT64) Ghcb->SharedBuffer; >>>>> + VmgSetOffsetValid (Ghcb, GhcbSwScratch); >>>>> + Status = VmgExit (Ghcb, SVM_EXIT_MMIO_WRITE, ExitInfo1, ExitInfo2); >>>>> + if (Status != 0) { >>>>> + return Status; >>>>> + } >>>>> + break; >>>>> + >>>>> // >>>>> // MMIO write (MOV reg/memX, immX) >>>>> // >>>>> @@ -809,6 +855,58 @@ MmioExit ( >>>>> CopyMem (Register, Ghcb->SharedBuffer, Bytes); >>>>> break; >>>>> >>>>> + // >>>>> + // MMIO read (MOV aX, moffsetX) >>>>> + // >>>>> + case 0xA0: >>>>> + Bytes = 1; >>>>> + // >>>>> + // fall through >>>>> + // >>>>> + case 0xA1: >>>>> + Bytes = ((Bytes != 0) ? Bytes : >>>>> + (InstructionData->DataSize == Size16Bits) ? 2 : >>>>> + (InstructionData->DataSize == Size32Bits) ? 4 : >>>>> + (InstructionData->DataSize == Size64Bits) ? 8 : >>>>> + 0); >>>>> + >>>>> + InstructionData->ImmediateSize = (UINTN) (1 << InstructionData->AddrSize); >>>>> + InstructionData->End += (UINTN) (1 << InstructionData->AddrSize); >>>>> + >>>>> + if (InstructionData->AddrSize == Size8Bits) { >>>>> + Address = *(UINT8 *) InstructionData->Immediate; >>>>> + } else if (InstructionData->AddrSize == Size16Bits) { >>>>> + Address = *(UINT16 *) InstructionData->Immediate; >>>>> + } else if (InstructionData->AddrSize == Size32Bits) { >>>>> + Address = *(UINT32 *) InstructionData->Immediate; >>>>> + } else { >>>>> + Address = *(UINTN *) InstructionData->Immediate; >>>>> + } >>>> >>>> (2) Similar question as (1). >>> >>> Will do. >>> >>>> >>>>> + >>>>> + Status = ValidateMmioMemory (Ghcb, Address, Bytes); >>>>> + if (Status != 0) { >>>>> + return Status; >>>>> + } >>>>> + >>>>> + ExitInfo1 = Address; >>>>> + ExitInfo2 = Bytes; >>>>> + >>>>> + Ghcb->SaveArea.SwScratch = (UINT64) Ghcb->SharedBuffer; >>>>> + VmgSetOffsetValid (Ghcb, GhcbSwScratch); >>>>> + Status = VmgExit (Ghcb, SVM_EXIT_MMIO_READ, ExitInfo1, ExitInfo2); >>>>> + if (Status != 0) { >>>>> + return Status; >>>>> + } >>>>> + >>>>> + if (Bytes == 4) { >>>>> + // >>>>> + // Zero-extend for 32-bit operation >>>>> + // >>>>> + Regs->Rax = 0; >>>>> + } >>>> >>>> (3) This is also seen with opcode 0x8B, but can you remind me please why >>>> we ignore (Bytes == 1) and (Bytes == 2) for zero extension? >>> >>> That comes from the APM Vol 3, Table B-1, that says, in 64-bit mode, for a >>> 32-bit operand size the 32-bit register results are zero-extended to 64-bits. >>> >>>> >>>>> + CopyMem (&Regs->Rax, Ghcb->SharedBuffer, Bytes); >>>>> + break; >>>>> + >>>>> // >>>>> // MMIO read w/ zero-extension ((MOVZX regX, reg/memX) >>>>> // >>>>> @@ -886,6 +984,7 @@ MmioExit ( >>>>> break; >>>>> >>>>> default: >>>>> + DEBUG ((DEBUG_INFO, "Invalid MMIO opcode (%x)\n", OpCode)); >>>>> Status = GP_EXCEPTION; >>>>> ASSERT (FALSE); >>>>> } >>>>> >>>> >>>> (4) We should use the DEBUG_ERROR log mask here. >>> >>> Will change. >>> >>> Thanks, >>> Tom >>> >>>> >>>> Thanks >>>> Laszlo >>>> >>>> >>>> >>>> >>>> >>>> >> >