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.92.42.11]) by mx.groups.io with SMTP id smtpd.web12.59423.1629312397476004759 for ; Wed, 18 Aug 2021 11:46:38 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@outlook.com header.s=selector1 header.b=IA6XHPdk; spf=pass (domain: outlook.com, ip: 40.92.42.11, mailfrom: michael.kubacki@outlook.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Kcl5o+jXKvnh+EcjZoUovKNZHp0kz9mgZ5N/Pm+ptlv2MzoSaxYGdHbMkAUlk+PuWIKy2p7wK3vUZ+prKLy7rBWjsBX/IJu9QZtrKP6V2RbjXU91ZSttlSVN1516VtvuWWAbBIzfZ8UpNoX2XkkR//VXl1TJRGSDhHTuHWK7EfQ6uo3nQ6ll2pGcvgpbFvSumC4XkgQjgzwkFEUbRZbvT/uimTz1Ox1zQf19C0G30dPInz6kIDHVB09t3vouFdDqqaRb+ltTx0HG7QSRyhmSsV/1IFIw8l1rH+VRgN3PRCh/uLmN07SnE/QpZX7fE3qGsrWSXxGvnAGxWPtufF6xZQ== 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=XWcQO9G7fWJMCbLLVPUecUz6NfSzo2WtvvhOHraGjNs=; b=a0nuQt/BfpWTF/n9Crx1rE3zFbkpKF4TuqUxxFIVCS+1RJraDb0K+WPWX0uorht1AEg4hmPffXfsEHrtxzYIaSW7vo8G69xxdiTuP9Lo2nYR5CAg+7vynBsudo05A3Cv4F366c26zHNXairtSIQlM8Q6gQfbkN4LZQm+4+950K3SiIXj6Y9x0G8CMLO4ua6HEhfC0ZiEKhk3gM3sTpHOZau+CI85oRq81fPPrktBtCwuwPe3Kn1tqnIoJu3ZhBQPrn9zNXoCYgMbI/OHq9HYJuXDHiKbk3AnOQQVJsR5ygBijvw0j9os640vGYH5WL37HBcMzLq3NOTxv2/VRo5Pag== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XWcQO9G7fWJMCbLLVPUecUz6NfSzo2WtvvhOHraGjNs=; b=IA6XHPdkrm+yUw8QmU3bKwGuUAHH0XVm0VlqCiIx55RcmH3yyodWLZuDkj/lUM0/Ooi3AX0HmSdPSAUcOu8xEx1YOklZt73zY9j67/FY52t61/X0mx9D5UnVgNbeJgO3gye/T7FefDuFUDhGaY8yQi82LgrZY5S1FE5iTndrRsnNU5Dv/bX9y3hogU1R9+cPuI0+AQU1G/K4IeDhrwjqrZPOm/3/Y99doL/cTAJ+pAynSewCFj/8geDZvh+CV4XM3eBnhWTK4a+tWTEYWbkUcWsFd0v0zrwm5ZuXy314DAF1YA8ZmwVX15P93mrZgSuB3taYCCvRiugpw0DGHhIHOA== Received: from DM6NAM10FT025.eop-nam10.prod.protection.outlook.com (2a01:111:e400:7e86::4c) by DM6NAM10HT192.eop-nam10.prod.protection.outlook.com (2a01:111:e400:7e86::63) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19; Wed, 18 Aug 2021 18:46:36 +0000 Received: from MWHPR07MB3440.namprd07.prod.outlook.com (2a01:111:e400:7e86::4e) by DM6NAM10FT025.mail.protection.outlook.com (2a01:111:e400:7e86::133) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19 via Frontend Transport; Wed, 18 Aug 2021 18:46:36 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:6BD715AE1C2365A569A04F59F162C2F5BB8B63420ADE5B17D67778FED616101C;UpperCasedChecksum:A4F383A50CCA534CC8D70F772FD555DAD8E2A81870733C303EE4D13ADE31B787;SizeAsReceived:9334;Count:47 Received: from MWHPR07MB3440.namprd07.prod.outlook.com ([fe80::a0a6:96f:f5d5:ca28]) by MWHPR07MB3440.namprd07.prod.outlook.com ([fe80::a0a6:96f:f5d5:ca28%3]) with mapi id 15.20.4415.024; Wed, 18 Aug 2021 18:46:36 +0000 Subject: Re: [edk2-devel] [edk2-platforms][PATCH v1 1/1] IntelSiliconPkg/PeiSmmAccessLib: Remove S3 requirement To: devel@edk2.groups.io, ray.ni@intel.com, "mikuback@linux.microsoft.com" , "Chaganty, Rangasai V" , "Yao, Jiewen" References: <20210809133938.2430-1-mikuback@linux.microsoft.com> <9a5c7c6b-70c5-c1c0-6405-51149013c295@linux.microsoft.com> From: "Michael Kubacki" Message-ID: Date: Wed, 18 Aug 2021 14:46:33 -0400 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 In-Reply-To: X-TMN: [nQkqBIvHN5SRH/aKOnkB9v7K7Jf+opa2JSFD62et5fqO1Tycm+YA31JkizTXYUbx] X-ClientProxiedBy: BN8PR15CA0005.namprd15.prod.outlook.com (2603:10b6:408:c0::18) To MWHPR07MB3440.namprd07.prod.outlook.com (2603:10b6:301:69::28) Return-Path: michael.kubacki@outlook.com X-Microsoft-Original-Message-ID: <83cc0387-d465-4ba8-affd-3ed9d973e41a@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from [IPv6:2601:703:0:bb0:f06d:7919:663f:5cdb] (2601:703:0:bb0:f06d:7919:663f:5cdb) by BN8PR15CA0005.namprd15.prod.outlook.com (2603:10b6:408:c0::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19 via Frontend Transport; Wed, 18 Aug 2021 18:46:34 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 47 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: eac92e0b-e64d-444f-d2c0-08d96278817a X-MS-TrafficTypeDiagnostic: DM6NAM10HT192: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: LOU4FDb7Rgianlelwxz8WdnD3G5zYsNj87n0rn6PhU0u4fWzDgi+w0yX2lx8dglLzgKeOKjX8N2gnOlmROCD+xpwykNjSntZgl9lr7VSZBhJgXDIR2M6D8gSB1AVweFibkCkSMvpYLgo1mNHYCI+5Z0s1CFy5/QZ9fMJPOoFiG+NXqQyzSz1KNQ6Sgb+YQOG1eR67ACR2UXOzmdvwlxuSEOCCo4BZxIL8c6Ewq4FTakgfF8Fec0JbqEL57SPhAJtoMdEwu8h4ZaduM/q0jGybmhYhbPowgKzVCfVWUoVzSRFNLnf7FbIbIyrP6YON2zkrL0wT/aAL0ylc3uETKLiz/63sruhNyXnvOqSo3tWHdB1gKm20MvErq2+DejlgF30heMCxEcTIaOdRcWx5LlQh3yw9SabuqPdeG5o41435iH6w8YpiNwDqV01Zg2uvIbVgbG3SWqk+O4xX8h3DWfhMZkFF/u0O/vdH5tv1J5P2Mo= X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 6aN8mhtY/o01XB1PPXQS7ch0QV0W5EbPJMNZ43PTFGxOK1Rev+5au2p6X3pUHfym6vupoUx48AUk8+O32EoG8UCRidWgvOAUF6l3vq45JaVkhO33qoF1YJ1uiQh39lw1r6Bw6rdd9Z77yE46fo54ZG7gI7FKGkiD02rGxpaUD4Tv8Yd1aAleFqfij3XbP8j//R1CCHiGZ626CKh2MCp97g== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: eac92e0b-e64d-444f-d2c0-08d96278817a X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Aug 2021 18:46:36.1861 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: DM6NAM10FT025.eop-nam10.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6NAM10HT192 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Jiewen/Sai, are you thinking about this? Thanks, Michael On 8/12/2021 1:20 AM, Ni, Ray wrote: > Michael, > I need Jiewen's input on why MmAccess and MmCommunication PPIs were not installed in normal boot path. Without understanding the reason, I don't have confidence to approve the change. > > Sai, > Do you see other impacts to Intel platforms with this behavior change? > > Thanks, > Ray > > -----Original Message----- > From: devel@edk2.groups.io On Behalf Of Michael Kubacki > Sent: Tuesday, August 10, 2021 11:36 PM > To: devel@edk2.groups.io; Ni, Ray ; Chaganty, Rangasai V > Cc: Yao, Jiewen > Subject: Re: [edk2-devel] [edk2-platforms][PATCH v1 1/1] IntelSiliconPkg/PeiSmmAccessLib: Remove S3 requirement > > Installation is a platform decision. The buried dependency on boot mode in this particular function is just a roadblock platforms have to work around. The role of this API is to install the PPI. > > Thanks, > Michael > > On 8/9/2021 9:47 PM, Ni, Ray wrote: >> Michael, >> Allowing the gPeiSmmAccessPpiGuid PPI installation in normal boot will >> further allow gEfiPeiSmmCommunicationPpiGuid installation in normal path, while without your change neither of the PPIs is installed in normal boot. >> >> + Jiewen for potential security concern. >> >> Thanks, >> Ray >> >>> -----Original Message----- >>> From: Chaganty, Rangasai V >>> Sent: Tuesday, August 10, 2021 6:46 AM >>> To: mikuback@linux.microsoft.com; devel@edk2.groups.io >>> Cc: Ni, Ray >>> Subject: RE: [edk2-platforms][PATCH v1 1/1] >>> IntelSiliconPkg/PeiSmmAccessLib: Remove S3 requirement >>> >>> Reviewed-by: Sai Chaganty >>> >>> -----Original Message----- >>> From: mikuback@linux.microsoft.com >>> Sent: Monday, August 09, 2021 6:40 AM >>> To: devel@edk2.groups.io >>> Cc: Ni, Ray ; Chaganty, Rangasai V >>> >>> Subject: [edk2-platforms][PATCH v1 1/1] >>> IntelSiliconPkg/PeiSmmAccessLib: Remove S3 requirement >>> >>> From: Michael Kubacki >>> >>> REF:https://bugzilla.tianocore.org/show_bug.cgi?id=3539 >>> >>> PeiInstallSmmAccessPpi() currently requires the boot mode be set to S3 to actually install gEfiPeiMmAccessPpiGuid. >>> >>> This change removes this requirement in the function implementation for two reasons: >>> >>> 1. Practical use cases exist to require this PPI in cases other than >>> the boot mode being set to BOOT_ON_S3_RESUME. >>> >>> 2. It is poor API design to implicitly bury this requirement within >>> a function whose responsibility is to install the PPI. The caller >>> can easily place arbitrary constraints around whether to call >>> based on conditions such as the boot mode being >>> BOOT_ON_S3_RESUME. >>> >>> Cc: Ray Ni >>> Cc: Rangasai V Chaganty >>> Signed-off-by: Michael Kubacki >>> --- >>> Silicon/Intel/IntelSiliconPkg/Feature/SmmAccess/Library/PeiSmmAccessLib/PeiSmmAccessLib.c | 12 ------------ >>> 1 file changed, 12 deletions(-) >>> >>> diff --git >>> a/Silicon/Intel/IntelSiliconPkg/Feature/SmmAccess/Library/PeiSmmAcces >>> sLib/PeiSmmAccessLib.c >>> b/Silicon/Intel/IntelSiliconPkg/Feature/SmmAccess/Library/PeiSmmAcces >>> sLib/PeiSmmAccessLib.c index d9bf4fba983e..4df0d695fdaf 100644 >>> --- >>> a/Silicon/Intel/IntelSiliconPkg/Feature/SmmAccess/Library/PeiSmmAcces >>> sLib/PeiSmmAccessLib.c >>> +++ b/Silicon/Intel/IntelSiliconPkg/Feature/SmmAccess/Library/PeiSmmA >>> +++ cce >>> +++ ssLib/PeiSmmAccessLib.c >>> @@ -252,19 +252,7 @@ PeiInstallSmmAccessPpi ( >>> EFI_SMRAM_HOB_DESCRIPTOR_BLOCK *DescriptorBlock; >>> SMM_ACCESS_PRIVATE_DATA *SmmAccessPrivate; >>> VOID *HobList; >>> - EFI_BOOT_MODE BootMode; >>> >>> - Status = PeiServicesGetBootMode (&BootMode); >>> - if (EFI_ERROR (Status)) { >>> - // >>> - // If not in S3 boot path. do nothing >>> - // >>> - return EFI_SUCCESS; >>> - } >>> - >>> - if (BootMode != BOOT_ON_S3_RESUME) { >>> - return EFI_SUCCESS; >>> - } >>> // >>> // Initialize private data >>> // >>> -- >>> 2.28.0.windows.1 >> >> >> >> >> > > > > > > > > > >