From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM02-CY1-obe.outbound.protection.outlook.com (NAM02-CY1-obe.outbound.protection.outlook.com []) by mx.groups.io with SMTP id smtpd.web11.13475.1574280499527396450 for ; Wed, 20 Nov 2019 12:08:20 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@amdcloud.onmicrosoft.com header.s=selector2-amdcloud-onmicrosoft-com header.b=FJ9V9B0m; spf=none, err=SPF record not found (domain: amd.com, ip: , mailfrom: thomas.lendacky@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mKwRz5z8tDXz6Yt8aj75hrZjujq1NRr6eno9dC4wvBs0A6xYdNUa/7XSdmm6q3rS5VoBXWJj4JfoXy+e9SxfGpriLBa4YqXmLeno642OEMRqqoYD2vXWXgyyZlmo4kRNUege0hyI3X2SL33qlZjNPuRDuXyGNdyU3KLtToSp/2Rc/8HUeKtdEcF4bU6kZc1B68w+mIYvG9qov+OWVRBdqsoXJxIRJQm1A5Xiab+luwXuhtThzZXkS3VSHuSH7JTBCUjWLWWFBdj9aG5ccl+W+MvrHc7xrtdzztEPIiw3Ta45U7SWdC6aw3gBYyeORrDoPeM7UkMHcBrIWPO7jZ9GBg== 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=whh82ZRiw2P5GqdMEWKnC+3FlcCBGwEIm94rJor6lbo=; b=PAymCws4/mVWvgnhxdQJRRT5Zl9CWwJ8GAivSBcw/gY828aCTOx2Jgi19RcsxwgyK4bv+b4sC270Q/Oue1/YhCSzbxUKX2oM5X06Allish9M7Qf1iCyWfos/GWPS3wFNVJxnYKYLwuhhn6lxXidC3UjZLIIT+Yim2hyEGFfBNhZWF86DlhvJflmSiYBdHsCIGbgKoc0F1fTXCQqDYaxl/syUMjeGBy05rE5t9DKd6bLbdAHDM6AMESdhKbQ2KbJ1AqrmMn97CHavsn5NLCToXAIhm17AAyobeQhOhC+Ifde4kPvr+ryozv2LC+R/aOK3lDjS8QqER+KHBNRlxlivsQ== 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=whh82ZRiw2P5GqdMEWKnC+3FlcCBGwEIm94rJor6lbo=; b=FJ9V9B0mOvRDaYQv2DrE//fWvyXk6b66dL7tOGlDCjqx1HIKBnWINywATN/dSbvw3G/3UDed4er3EOmSDhrLnXwZgrpbd4UrC5kcFFQVqPfFf95E2xS4g/W72nYXC/joxrgH0jfFk0gOOgkxmhCdD7joMSWhYAsPSWxJUwQOFvQ= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Thomas.Lendacky@amd.com; Received: from DM6PR12MB3163.namprd12.prod.outlook.com (20.179.71.154) by DM6PR12MB3675.namprd12.prod.outlook.com (10.255.76.80) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2451.28; Wed, 20 Nov 2019 20:08:19 +0000 Received: from DM6PR12MB3163.namprd12.prod.outlook.com ([fe80::dd0c:8e53:4913:8ef4]) by DM6PR12MB3163.namprd12.prod.outlook.com ([fe80::dd0c:8e53:4913:8ef4%5]) with mapi id 15.20.2451.031; Wed, 20 Nov 2019 20:08:19 +0000 From: "Lendacky, Thomas" To: devel@edk2.groups.io Cc: Jordan Justen , Laszlo Ersek , Ard Biesheuvel , Michael D Kinney , Liming Gao , Eric Dong , Ray Ni , Brijesh Singh , Jian J Wang , Hao A Wu , Dandan Bi Subject: [RFC PATCH v3 33/43] MdeModulePkg: Reserve a 16-bit protected mode code segment descriptor Date: Wed, 20 Nov 2019 14:06:55 -0600 Message-Id: X-Mailer: git-send-email 2.17.1 In-Reply-To: References: X-ClientProxiedBy: DM3PR12CA0087.namprd12.prod.outlook.com (2603:10b6:0:57::31) To DM6PR12MB3163.namprd12.prod.outlook.com (2603:10b6:5:15e::26) Return-Path: thomas.lendacky@amd.com MIME-Version: 1.0 X-Mailer: git-send-email 2.17.1 X-Originating-IP: [165.204.77.1] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 83058277-57b2-415b-8497-08d76df5518c X-MS-TrafficTypeDiagnostic: DM6PR12MB3675: X-MS-Exchange-PUrlCount: 1 X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:4303; X-Forefront-PRVS: 02272225C5 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(4636009)(136003)(396003)(366004)(39860400002)(346002)(376002)(199004)(189003)(36756003)(6506007)(51416003)(446003)(66946007)(76176011)(52116002)(50466002)(386003)(478600001)(6116002)(3846002)(14454004)(48376002)(5660300002)(966005)(6306002)(6666004)(14444005)(186003)(26005)(6512007)(19627235002)(4326008)(6436002)(2906002)(6486002)(99286004)(50226002)(2361001)(7416002)(8676002)(81156014)(81166006)(8936002)(118296001)(2351001)(316002)(86362001)(6916009)(66066001)(16586007)(7736002)(305945005)(47776003)(25786009)(66556008)(66476007)(486006)(11346002)(54906003)(476003)(2616005);DIR:OUT;SFP:1101;SCL:1;SRVR:DM6PR12MB3675;H:DM6PR12MB3163.namprd12.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: wI5jRe9XLyvXNZGNYV/j5VuWe3LJXS2YWlyyNQq2JZgtsmiN6Y+/SVBoxCfDANk0S2piUfIgjgXr9WpQ9By1jt8jW3wWhAXDSUQFMJ92Q0oV+9jtQh/cRgtlf8vCPO5tRZ4TTC31n2INVuAho4Stfxo8AOI0jQXmzf8ZuKCDgxYJvEMjQanJx/5mC2tuHvvyuLhvL2NQ/2WHfBqj+K2KW1g2yp0Xq19QUxG/Fh5zyHvfcYu+rL1Z0RVx7W3JTYhe0oK+QGR4CVa/0W4Xcp7mIlitxL/Ly6pJRCzTsaIZW9hfeH6+c+NAdy0HEZRWWufc/b72ua1YPMCM0bUrYHVQBYAtNFLw/RbkiZVlpoe9R6YWWap1K75xyBeASt2UiyPaXO5kx6dBqJwTT7M3NirECkzRXTitT/yZjwbbSLcxNVcOhrLuVKVMlGIkjQW27WFUGVW8AlgbD0qDpR2ZV4AL58VXR0/82zP6DtI3D95a20w= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 83058277-57b2-415b-8497-08d76df5518c X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Nov 2019 20:07:50.0252 (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: 64JUYQhrL457tFtwNiZGRvaFxY+tbxJnyr1FlUI6a78Z6Wpub4xB1sczFuVWYHZ8oJkXk1nZiJ7X6WJ8O6pvqg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB3675 Content-Type: text/plain BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2198 SEV-ES guest AP boot support needs to transition from 64-bit long mode into 16-bit real mode. This will require a 16-bit code segment descriptor. Reserve one of the spare segment descriptors (0x28) for this purpose. Cc: Jian J Wang Cc: Hao A Wu Cc: Dandan Bi Cc: Liming Gao Signed-off-by: Tom Lendacky --- MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c b/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c index 284b34818ca7..c9cf2e36214f 100644 --- a/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c +++ b/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c @@ -33,7 +33,7 @@ GLOBAL_REMOVE_IF_UNREFERENCED IA32_GDT gGdtEntries[] = { /* 0x10 */ {{0xffff, 0, 0, 0xf, 1, 0, 1, 0xf, 0, 0, 1, 1, 0}}, //linear code segment descriptor /* 0x18 */ {{0xffff, 0, 0, 0x3, 1, 0, 1, 0xf, 0, 0, 1, 1, 0}}, //system data segment descriptor /* 0x20 */ {{0xffff, 0, 0, 0xa, 1, 0, 1, 0xf, 0, 0, 1, 1, 0}}, //system code segment descriptor -/* 0x28 */ {{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}}, //spare segment descriptor +/* 0x28 */ {{0xffff, 0, 0, 0xa, 1, 0, 1, 0xf, 0, 0, 0, 1, 0}}, //system code16 segment descriptor /* 0x30 */ {{0xffff, 0, 0, 0x2, 1, 0, 1, 0xf, 0, 0, 1, 1, 0}}, //system data segment descriptor /* 0x38 */ {{0xffff, 0, 0, 0xa, 1, 0, 1, 0xf, 0, 1, 0, 1, 0}}, //system code segment descriptor /* 0x40 */ {{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}}, //spare segment descriptor -- 2.17.1