From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM11-BN8-obe.outbound.protection.outlook.com (NAM11-BN8-obe.outbound.protection.outlook.com [40.107.236.86]) by mx.groups.io with SMTP id smtpd.web11.1532.1588964337202432901 for ; Fri, 08 May 2020 11:58:57 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@amdcloud.onmicrosoft.com header.s=selector2-amdcloud-onmicrosoft-com header.b=rNXkpbZc; spf=none, err=SPF record not found (domain: amd.com, ip: 40.107.236.86, mailfrom: thomas.lendacky@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UdLfs5bnJd89+QJUCswq5HRdKYozZBXa61PyO4LbS6S9OR0sr+atbqa4vetWGBQRtT8OJChnsEssVknXqo5TK+yzJCAJq3YfXF+NzsjVzYUiC3CLOXV1JTkmyF+/eyCCgcHMxJXfwOeoTwH5/NdoEZj6mndmwWoeyKTIK6jEgEhNB2eeNc7tRK1T1KpThujLrwToBcEK2gDFBhygz3+D3Kd+/XJhGHXqBmkzvQ7rrW2dnhIeW0uDUS9Rf8zLQt0fEFDlfHndsKeeCJzMbrE1s85+Dq127CCL4xAj6p+EteaA03t5hwKlg5yUPU1V7MhL6NJUeCAAfIaBagCJuI0Quw== 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=FjYtJ2+iBd9UBbpWoX3Z45IIFZnsbblnAhz90nVS1Xg=; b=INQq+wmUsqu+rCUu7ixo/MktpDuOUPizzcY//vzhXIzAijgFNzkTDbj1kjNRWVpz/Sh6V9kfoLw/oKT4vJBKlvfisCWB4D+rT+INzPjnRJcR1aEr0U0NPCYhh0AQn0NKYr5FvUUWbQ5JbvL9W1qfZVIjYeqjRCfcpHxNnGHH1FEO9JYFs1sMwpceQQN9H5nJ5Zj0vRonB5dathiXefbv6A/MURxZWpkQOEZ0Mh0DriiCbGqKeuDW1dBLWuI0T1RKv8Jc3EBuJadiYG++gJ8UG0MQIEcKSdCCNAn5lefC949Ez0JIsbW57KUuniLoltSxT5NUZtSxTwYesZlr5vlVcQ== 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=FjYtJ2+iBd9UBbpWoX3Z45IIFZnsbblnAhz90nVS1Xg=; b=rNXkpbZcbdp3AUXBiBKpFrYGOM7vA/kcWcgBBpWfwoMJEVA6+2y70nyuyEkjAmaZUK2Iv7P7DsF1BqMATlHFKOepjHHvXjfG0aCYu9huLMelTrilrYBJMhhAAoeb7j52Xvq3K+pCgaRtwGhzGHx6xseZqDz8hd7udPBVDUk053Y= 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 DM5PR12MB1593.namprd12.prod.outlook.com (2603:10b6:4:10::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2979.28; Fri, 8 May 2020 18:58:55 +0000 Received: from DM5PR12MB1355.namprd12.prod.outlook.com ([fe80::4ce1:9947:9681:c8b1]) by DM5PR12MB1355.namprd12.prod.outlook.com ([fe80::4ce1:9947:9681:c8b1%10]) with mapi id 15.20.2958.034; Fri, 8 May 2020 18:58:55 +0000 Subject: Re: [edk2-devel] [PATCH v7 01/43] MdeModulePkg: Create PCDs to be used in support of SEV-ES To: "Dong, Eric" , "devel@edk2.groups.io" , "lersek@redhat.com" Cc: "Justen, Jordan L" , Ard Biesheuvel , "Kinney, Michael D" , "Gao, Liming" , "Ni, Ray" , Brijesh Singh , "Wang, Jian J" , "Wu, Hao A" References: <3af2e4a8-fa4d-bb29-a282-c406ada7cf06@amd.com> <66c3ab32-0b1c-676b-2924-f14214be5de6@redhat.com> <226c8566-6550-613c-e07c-636686a851f9@amd.com> <13992141-8be7-bdb4-e104-9036dddbb04d@amd.com> From: "Lendacky, Thomas" Message-ID: <55177c7d-7602-0f60-df34-dd411fa0e341@amd.com> Date: Fri, 8 May 2020 13:58:52 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 In-Reply-To: X-ClientProxiedBy: SN4PR0501CA0132.namprd05.prod.outlook.com (2603:10b6:803:42::49) 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 SN4PR0501CA0132.namprd05.prod.outlook.com (2603:10b6:803:42::49) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3000.12 via Frontend Transport; Fri, 8 May 2020 18:58:53 +0000 X-Originating-IP: [67.79.209.213] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 326911f5-b1a6-461a-fb53-08d7f381db07 X-MS-TrafficTypeDiagnostic: DM5PR12MB1593:|DM5PR12MB1593: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:7691; X-Forefront-PRVS: 039735BC4E X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 3X4DHU/6eJk1p+IHciwysyMLSD9MdACvehxebkp5z6ACc/XpK1SfEihuGk5g+O0KuQieojRcJjfAFmkjOpxMTwtz+g/kTCcUiZ/R6/QdrTvAwzaKDBkMM1Vvq4xilE9c7AtKiVcQSLAK5LvniTlswEYU2zIA4IvQCHq7Sb8233pmRc/odFfjUv/iZJPjjE+b+GRgmdfY9CGrzARAyaAMZwcpL6Gj36qvnOmlNjCAMWHXRuS5olKcVcPTPaUSjykfsYioCvHHB7VQe5sowVGEXWxBs7f4dNNaGwVWC32m7C1cG2jdep1iXLBUh1UBhDPfWEM7QWPTTSPsgzFPoKPy3Vu35haiEbfBrU+b5pdixg0aXhDcZ9I7g2rs/eATKfb6P2MXJo3Se+S0KTaIWGf+hoAnum5ZtWhizrqfbLqvXuMEXJKcAAuN3zqP9Z4zLBhdi4B3xpY93KXMhdx8kPm35jehUVz2HK964O/BP2qZmvW63fzP8T1NRssK2Ee1WWglzU0duzqk4VUha+IA4dXRWCrSy4Xq4d0juDhENAezbl/2Z1N2lnQzww8BSDdIjW8cGEOxXOZSxAGiEMamQEnAJFbG7CQFOPg2wdPUM2fTRhVj2v7Do6Sj2UXHJL2Q2kI3 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;SFTY:;SFS:(4636009)(136003)(39860400002)(396003)(366004)(346002)(376002)(33430700001)(31686004)(52116002)(5660300002)(53546011)(6506007)(8676002)(83290400001)(83310400001)(26005)(83300400001)(83320400001)(4326008)(30864003)(478600001)(7416002)(83280400001)(83080400001)(45080400002)(86362001)(110136005)(2906002)(31696002)(2616005)(316002)(36756003)(19627235002)(966005)(186003)(33440700001)(8936002)(66556008)(16526019)(66476007)(66946007)(6486002)(6512007)(956004)(54906003)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData: GYCLjKBabNIX9H7aqpkXf4jalyA0s4RfB2FWroojTcqKI8AWxLup6RSGjsVK5pyDqZJIp79D9z0zj/59y1QCilmWLvwUetejepkGHHsP0YYZ6BVKslaUrCu4z3rk6qWkHEa+OiFqXXP0m304rBzuFv4UTBNaRMe13sfHbW446H0TfUbYkPJSFagH844QERnYOsvhRnSaBejrpeCE+XjVi3Cn72vfC/0AVflomSKPzDEvn4d7S+6ZusznT8lZWWSvNZk7ikFTSbu00QMpVVkEVM8o+ppP0DTm8CjJXt4fxkABHsr1OrR6KBnDIuL2CdoULe0g1JQCTvEYj3zFwyrb88EC7IM1uOr76GF7sj4nFBI3kRtXi23XQbj22TBz5rCeePQNpHTCPpd6GD4Vfljb5gV59IMfr/QVluRZZv9mXQPwi9/WVRXcZ9zPqUwS+8QkugqP/D3PymYHXlcV8MLeXwgwMQD9elKrRQK2ezM4v/k= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 326911f5-b1a6-461a-fb53-08d7f381db07 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 May 2020 18:58:55.0397 (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: mtOdRRch1P1Eggi1q6jKnB73i2+n3925MaDK4wl3QxMZVLfKzEwhd8bcn6lxMqRhuyyGLBVgSAPHOAExbLHutg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1593 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit On 5/6/20 9:38 PM, Dong, Eric wrote: > Hi Tom, Hi Eric, > >> -----Original Message----- >> From: Tom Lendacky >> Sent: Thursday, May 7, 2020 2:33 AM >> To: Dong, Eric ; devel@edk2.groups.io; >> lersek@redhat.com >> Cc: Justen, Jordan L ; Ard Biesheuvel >> ; Kinney, Michael D >> ; Gao, Liming ; Ni, Ray >> ; Brijesh Singh ; Wang, Jian J >> ; Wu, Hao A >> Subject: Re: [edk2-devel] [PATCH v7 01/43] MdeModulePkg: Create PCDs to >> be used in support of SEV-ES >> >> Hi Eric, >> >> On 5/6/20 10:06 AM, Dong, Eric wrote: >>> Hi Tom, >>> >>>> -----Original Message----- >>>> From: devel@edk2.groups.io On Behalf Of >>>> Lendacky, Thomas >>>> Sent: Wednesday, May 6, 2020 9:20 PM >>>> To: Dong, Eric ; devel@edk2.groups.io; >>>> lersek@redhat.com >>>> Cc: Justen, Jordan L ; Ard Biesheuvel >>>> ; Kinney, Michael D >>>> ; Gao, Liming ; Ni, >> Ray >>>> ; Brijesh Singh ; Wang, Jian >> J >>>> ; Wu, Hao A >>>> Subject: Re: [edk2-devel] [PATCH v7 01/43] MdeModulePkg: Create PCDs >> to >>>> be used in support of SEV-ES >>>> >>>> On 5/5/20 8:53 PM, Dong, Eric wrote: >>>>> >>>>> >>>>>> -----Original Message----- >>>>>> From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf >> Of >>>>>> Laszlo Ersek >>>>>> Sent: Tuesday, May 5, 2020 11:30 PM >>>>>> To: Tom Lendacky ; Dong, Eric >>>>>> ; devel@edk2.groups.io >>>>>> Cc: Justen, Jordan L ; Ard Biesheuvel >>>>>> ; Kinney, Michael D >>>>>> ; Gao, Liming ; >> Ni, >>>>>> Ray ; Brijesh Singh ; >> Wang, >>>>>> Jian J ; Wu, Hao A >>>>>> Subject: Re: [edk2-devel] [PATCH v7 01/43] MdeModulePkg: Create >> PCDs >>>>>> to be used in support of SEV-ES >>>>>> >>>>>> On 05/04/20 18:41, Tom Lendacky wrote: >>>>>> >>>>>>> Is there an easy way to run everything that this link points, too? >>>>>>> Is it just creating a pull request that does this? I don't want to >>>>>>> take up a lot of your time, so if there's some documentation on how >>>>>>> to run an integration test to find and fix issues like this, just point me >> to it. >>>>>> >>>>>> Just create a pull request; it will set off CI, and you can review VS >>>>>> build errors there (if any). >>>>>> >>>>>> Your PR will automatically be closed (rejected) regardless of whether >>>>>> CI succeeds or not. PRs are merged -- in fact, *auto*-merged, by the >>>>>> "mergify bot" -- if and only if (a) the CI run succeeds, and (b) the PR has >>>> the "push" >>>>>> label set. >>>>>> >>>>>> And only edk2 maintainers have permission to set the "push" label. >>>>>> Any PR without the "push" label qualifies as a "personal test build". >>>>>> So you can freely experiment with PRs, because you can't (even >>>>>> unwittingly) satisfy condition (b). >>>>>> >>>>>> >>>> >> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgit >>>>>> hub.com%2Ftianocore%2Ftianocore.github.io%2Fwiki%2FEDK-II- >>>> Development >>>>>> - >>>> >> &data=02%7C01%7Cthomas.lendacky%40amd.com%7C9cff3475aff84a9 >>>> 57285 >>>>>> >>>> >> 08d7f1604c99%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C63724 >>>> 326821 >>>>>> >>>> >> 7382019&sdata=3%2FIKB174QaVLaqO0u1gdrL0izXmhEZ%2Byvj3iC13UYB >>>> c%3D& >>>>>> amp;reserved=0 >>>>>> Process >>>>>> >>>>> >>>>> Thanks Laszlo for your explanation. >>>>> >>>>> I found this patch serial is incompatible for the existed platforms. >>>>> Can you help to fix the build failure for these platforms in >>>>> >>>> >> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgith >>>>> ub.com%2Ftianocore%2Fedk2- >>>> platforms&data=02%7C01%7Cthomas.lendacky >>>>> %40amd.com%7C9cff3475aff84a95728508d7f1604c99%7C3dd8961fe4884 >> e6 >>>> 08e11a8 >>>>> >>>> >> 2d994e183d%7C0%7C0%7C637243268217382019&sdata=jU0qrB%2BV6Z >>>> vFmPzjcx >>>>> Go9o2Pu1%2FrhRW0gUZTMv%2BiXDQ%3D&reserved=0 >>>>> >>>> >>>> I have fixed all of the build issues associated with the VS compiler using >> the >>>> pull request method that Laszlo mentioned. I then successfully built the >> RPi4 >>>> platform under GCC (build -n 32 -a AARCH64 -t GCC5 -p >>>> Platform/RaspberryPi/RPi4/RPi4.dsc) using the AARCH64 cross compiler. >>>> >>>> Is there a particular platform that experiences an issue or are the failures >>>> related to the VS compiler errors that my next series will have fixed? >>> >>> I used the KabylakeRvp3 platform with your changes in Edk2 and met >> failures. >>> KabylakeRvp3 code at Edk2- >> platforms\Platform\Intel\KabylakeOpenBoardPkg\ >>> >>> I used below command to build the code. >>> C:\Code\OpenSource\edk2-platforms\Platform\Intel>build_bios.py -- >> platform KabylakeRvp3 >>> >>> You need clone below repositories to build the code. >>> Edk2: git@github.com:tianocore/edk2.git >>> Edk2-Platform git@github.com:tianocore/edk2-platforms.git >>> edk2-non-osi : git@github.com:tianocore/edk2-non-osi.git >>> FSP: git@github.com:IntelFsp/FSP.git >> >> On my Linux system, I cloned all the libraries and set the WORKSPACE and >> PACKAGES_PATH env variables, sourced edksetup.sh and issued: >> >> python3 edk2-platforms/Platform/Intel/build_bios.py --platform >> KabylakeRvp3 >> >> and got the following errors: >> >> Traceback (most recent call last): >> File "edk2-platforms/Platform/Intel/build_bios.py", line 1097, in >> main() >> File "edk2-platforms/Platform/Intel/build_bios.py", line 1067, in main >> platform_config = get_platform_config(arguments.platform, build_config) >> File "edk2-platforms/Platform/Intel/build_bios.py", line 904, in >> get_platform_config >> path = platform_data.get(platform_name) >> AttributeError: 'NoneType' object has no attribute 'get' >> >> I don't know what I'm missing as to why this error pops up. How is this >> done on a Linux system? > > Can you run the command in Intel directory? Seems like you not run it in Intel directory now. > > Change to Intel directory then run python3 build_bios.py --platform KabylakeRvp3 Ok, running out of the Intel directory worked. I have fixed all of the issues that were identified by the CI tool for VS compiler and after modifying the platform DSC files to include the VmgExitLib library, I was able to successfully build the KabylakeRvp3 platform. Thanks, Tom > > Thanks, > Eric >> >> Did your build fail because of the VmgExitLib library not being specified? >> If the platform includes the CpuExceptionHandlerLib or MpInitLib libraries >> then it will now also need to include the VmgExitLib library. >> >> I wish the build system could figure out that because the VmgExitLib >> library is specified in the various CpuExceptionHandlerLib INF files and >> the various MpInitLib INF files, it would automatically know to include it >> in whatever uses those libraries. It doesn't seem right that you would >> have to know and specify the library requirements of a library you are >> including when the system could figure it out. >> >> Thanks, >> Tom >> >>> >>>> >>>>> I think you also needs to add an wiki page to explain what need to do if >> an >>>> platform needs to integrate your changes, also it's better to explain this >>>> feature in the page. >>>>> >>>> >> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgith >>>>> >>>> >> ub.com%2Ftianocore%2Ftianocore.github.io%2Fwiki&data=02%7C01%7 >>>> Ctho >>>>> >>>> >> mas.lendacky%40amd.com%7C9cff3475aff84a95728508d7f1604c99%7C3dd89 >>>> 61fe4 >>>>> >>>> >> 884e608e11a82d994e183d%7C0%7C0%7C637243268217382019&sdata=x >>>> LkoV4zW >>>>> hxtsbqszqPc0lEAl%2BYLL%2B2wg1nIXql8a64E%3D&reserved=0 >>>> >>>> I don't see any platform other than OVMF using this feature as it is a >>>> virtualization feature. Having said that I can add an explanation of what is >>>> needed should another virtualization platform be created under EDK2 >> that >>>> wants to support SEV-ES. And, as you said, I can also explain the feature >>>> overall on the page. >>>> >>> >>> I think your page includes two parts, one is how to change the platform >> code to make the platform pass build, >>> the other is if the platform needs to enable the virtualization feature, how >> to enable it. >>> >>>>> >>>>> >>>>> If you want to include this change in the next edk2 release, you need >>>>> to add one item for it in the release plan page, sample can be found >>>>> in below pages: >>>>> >>>> >> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgith >>>>> ub.com%2Ftianocore%2Ftianocore.github.io%2Fwiki%2FEDK-II-Release- >>>> Plann >>>>> >>>> >> ing&data=02%7C01%7Cthomas.lendacky%40amd.com%7C9cff3475aff84 >>>> a95728 >>>>> >>>> >> 508d7f1604c99%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C6372 >>>> 4326821 >>>>> >>>> >> 7382019&sdata=kcDVjYHMS9bRRZOlKEk5ynFNT39AnxchJAMak%2Bn870 >>>> I%3D& >>>>> ;reserved=0 >>>> >>>> Thanks. Is there anyone in particular that I need to request this feature be >>>> added? >>> >>> You can syn with Liming, he is the edk2 release manager. He owns edk2 >> stable tag release task. >>> >>> Thanks, >>> Eric >>>> >>>> Thanks, >>>> Tom >>>> >>>>> >>>>> >>>>> Thanks, >>>>> Eric >>>>> >>>>>> Thanks, >>>>>> Laszlo >>>>>> >>>>>> >>>>>> >>>> >>>> >>>