From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by mx.groups.io with SMTP id smtpd.web09.1580.1661279640306316170 for ; Tue, 23 Aug 2022 11:34:00 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=SDUMt0nt; spf=pass (domain: intel.com, ip: 192.55.52.136, mailfrom: isaac.w.oram@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1661279640; x=1692815640; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=0PTavj/63nbraJgWrmc6oTX+ar5FZu0x1quYc4SsqEs=; b=SDUMt0ntndKwNfvFl/G285OtqQstqn0hp+OjybMLowXv5x5bqxWXpJ2D kMysCSK492OHoaMLoSAf7Iiw1HnRhe0N/EL6JxSVmoFDvyP7jCbgpaEhG p5paKmAxA0aXkNb/oVcRMXYzUaSbq975MMoiE0RnuJr77ZrpgUaNWESAR +8AZTeTuhfFLG5mSxNsPmAMorXNQAA1AaqlMb2IRt18lVxq8wflYEd3qv iWCTw0emxA6Kl4ey2ZFUTX/qlYIR4HxTqIMba5h00gXrv/DR0aAzvTjn4 AhxIHm0zh3HQ2M7jhOMnOeICKceHGRj6wNzdd9OXwMU4cZLfHalsQD67P A==; X-IronPort-AV: E=McAfee;i="6500,9779,10448"; a="273520800" X-IronPort-AV: E=Sophos;i="5.93,258,1654585200"; d="scan'208";a="273520800" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Aug 2022 11:33:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,258,1654585200"; d="scan'208";a="937576052" Received: from orsmsx603.amr.corp.intel.com ([10.22.229.16]) by fmsmga005.fm.intel.com with ESMTP; 23 Aug 2022 11:33:59 -0700 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 23 Aug 2022 11:33:59 -0700 Received: from orsmsx611.amr.corp.intel.com (10.22.229.24) by ORSMSX607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 23 Aug 2022 11:33:59 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx611.amr.corp.intel.com (10.22.229.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31 via Frontend Transport; Tue, 23 Aug 2022 11:33:59 -0700 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (104.47.57.176) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2375.31; Tue, 23 Aug 2022 11:33:58 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kIULWXpkr4Uq2JlBp7in+ulb+WXTLTiJTn3XDqvJ/cog4pQDYBbSBYxYXRpP/T6UQPTrmSwJbbXJW0cL1UBI7PCbx95rZ+CL+MtdDyL+tmWBbkbewIX/RYyiSnt/in/O3W47sFq4+jhQC3pQM21BXvEs93bTs26pR3RWTPGLzvsBPN6lq6CEhDTYdizVFgJYNczUZ2LSVpp+zYVcWF+or+7FV89jl9Ycjq0BDIVgYqwsu+lRhcT+/fioM4hY8UwMgPKY8D1PQ4WTdn3D2461Ugr2e/HSCLJt4s60b2SVctTuYGziCZP3sZ3HlIxcuuPkg/hQCMPIg2mzOqe9ma431g== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=rHMeVxHFJx0fq6CXFkEz1MUiSDg4phpGBtYCRz2eNRA=; b=JxG44TRmWWnAjrLou9IjTiTlnLOpHB+3jtpEfcyKpaQpYb9Feolk9nQWDE8GbSSQuRRVTLuyoxTxoLstzaL4hrCeBIi7rp03TjJ8qB/3IAdGuG4v5PSOSYJT74jxUHbd6zeGYAzahzxYOKDtVxi3KX2XUn/SUBRsRrBnBcEVg0aBf+93Iz5v+Qlmih50CNiQXFud87P1OwYeoSt4Ol38+lmJ/HDelVev6mCz39SceapfA4ATtfBk1w9GJjR0b6PLOxNg5edXNq+wkLCdfhxje2Ix2OyBXnAFUcpYqrgIrR/I7VMiLGesB4apn0dl79bvFwWnESQkOYyTVGhGeJiWEw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from SA1PR11MB5801.namprd11.prod.outlook.com (2603:10b6:806:23d::13) by SN6PR11MB2544.namprd11.prod.outlook.com (2603:10b6:805:5d::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5546.21; Tue, 23 Aug 2022 18:33:55 +0000 Received: from SA1PR11MB5801.namprd11.prod.outlook.com ([fe80::d1ab:10f2:3d04:2b09]) by SA1PR11MB5801.namprd11.prod.outlook.com ([fe80::d1ab:10f2:3d04:2b09%4]) with mapi id 15.20.5566.014; Tue, 23 Aug 2022 18:33:55 +0000 From: "Oram, Isaac W" To: "devel@edk2.groups.io" , "mikuback@linux.microsoft.com" CC: "Chiu, Chasel" , "Desimone, Nathaniel L" , "Gao, Liming" , "Dong, Eric" Subject: Re: [edk2-devel] [edk2-platforms][PATCH v2 1/1] MinPlatformPkg: Add FspNvsBuffer compression option Thread-Topic: [edk2-devel] [edk2-platforms][PATCH v2 1/1] MinPlatformPkg: Add FspNvsBuffer compression option Thread-Index: AQHYtp/DaUsNYq0gf0qb8c1nG96ZMa28yJAQ Date: Tue, 23 Aug 2022 18:33:55 +0000 Message-ID: References: <20220823032253.1686-1-mikuback@linux.microsoft.com> In-Reply-To: <20220823032253.1686-1-mikuback@linux.microsoft.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.6.500.17 dlp-reaction: no-action authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 55c80fdb-917e-44dd-e05e-08da8536093f x-ms-traffictypediagnostic: SN6PR11MB2544:EE_ x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: y7YclR5MtrkoAehqvFfVY9amw2PaGuOj8L5j0i1uDnJgyXTuNacKUawjcbLWqMlnAg9OcL3fWD0Do3yZMrr16F64/dJTmT3TWJC3eWMBFA/kfTbnG19NvsDMqPIuHZMKr/llZXn4K6pocz8PoUqGO6QC19nCAr9Ss4E5duIbxVUZ4DyZst53HgP1Eq95mK6PKwAW9cKPjqcV2k2R/1Bp8/VWdV/AI1B4IR6z+IEd0qnBcCfJR+iOmJBlb2QiXVvIUzSt6BruGIfOLT69ZqSMxgiFk+On2F7gD04eN6SVYfzWKtpy99uR7zIYeEBoURvwhltqtSX6ikOpQ8djxvj2yvNMT7VgjjmG4GbcEJhE5eArbCJ0iD8HXhtGgqOo0j8NinFwqp+eeOwLAJsiOZs9NjQ4JEJ2Z8zVe9UyEnqH1vjtssL+bmq9UJhmYSsFWhqd+rGuJzZ5LJjRkXVJEhf/4ZOMuQE/ohBuOBr4LEx0LZuuA4NdIwx3tD11Mcoos14i5bTSuA5ZQ56dVMNtSZ9HfIgvTgcp9ohaRLZwLhFK8xRPwg0m2McSxUFNAji2jv2YxCQXFk1W6v4bjs5oqZJatYjpjpV4UkzPThqvdoWm1HgtKvKgbTb52uAP1aRVpl6Yk4dP9DmuJ5kx7CtfzfoSETtOtdU/gbpZaTiYLJm+8pN3Kn9fzasMuBGrWhg3Ji5tOT3QsnrCtdtmSswopMyANkzsxHx7ekekJKqGXtKfCcWx2df2Lxfk/00Mzq1iuAwjhR5TXPUYvuKoSREEkHUdi+3Q2DO+I0l8SRkQ2t5J/vD8WyLOsv8QxdwbCDM5R5QTcggaz5c+0CvWs9gpiDNW4A== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SA1PR11MB5801.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(39860400002)(346002)(136003)(396003)(376002)(366004)(26005)(53546011)(33656002)(6506007)(2906002)(7696005)(19627235002)(9686003)(86362001)(107886003)(8936002)(5660300002)(52536014)(38070700005)(966005)(82960400001)(478600001)(45080400002)(55016003)(41300700001)(71200400001)(38100700002)(83380400001)(122000001)(186003)(110136005)(66556008)(66446008)(316002)(66476007)(64756008)(54906003)(4326008)(8676002)(66946007)(76116006);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?nm4hwkGf0oUkY79q/InpUG87AD7nWE4R0mu8sduklHzuJlrIQtw6aiXRsVS+?= =?us-ascii?Q?UXMbEGDjMb6tu4wPToh92AX0Of8IRJkMro65Ln4xAn4ueV17dZJfpDUl//dD?= =?us-ascii?Q?BJuclQtjffwwr4hd6h31O6kmpEfDFRNt9i01PYYbp0eHH1flRj4wn9d9v1s8?= =?us-ascii?Q?vd5H/c//mjMrsS2wFEAi+R4PghynkVX+gb5svLIX2A9+Vlt90Wo+aVWub3F0?= =?us-ascii?Q?Zih+DQO5VPhrLZBsNcSWWU3Zs3WeDDGyu67bEallndzV+ofRTn+WFIkNOaIy?= =?us-ascii?Q?7hDxyJ923BGVco6OIlFzg7vyOhwiuSP8d3krFGaf6qBF76Jk35ju51fn7q/j?= =?us-ascii?Q?4tzuJXc7d67GjQGQH2xq+qOYAFnMqrCA+oRxnGWoMbjqnPdPrwp00MU4qekg?= =?us-ascii?Q?bFSkAWJELPLmC/cU/sEOyaLfDz77qeQ3oTc/Jprj78I0enkBhFIxbtUl4lpc?= =?us-ascii?Q?64RDtL3t3IOmPCnAlrQFzcK50eo242dsShdGu/EcHYgcPUl6SGJW0Dfnh5id?= =?us-ascii?Q?QAm3U+3CgAgDXZj3x657UX5YrUt4LLGsYdQU2CXpd2T91CHkeFtSUYC/TSbH?= =?us-ascii?Q?GKNmg9GPkP3EWRR7bgs4vMC1RgVe2JnqexawjIYNJJ80GewelMiY41/37/0n?= =?us-ascii?Q?KF+QGTLWsgw5bTEGZIXaGFIMhTNx413OuHjJFq+RJMKO97FRvsKO7LDVzVsc?= =?us-ascii?Q?sDmQdvyMVfqFst6Ji5C6RBa7i56QtV9O6vousRPhzFOWLnY1ro6+jrI2pTqE?= =?us-ascii?Q?uqQuz+41R+Cgx/b2Zj4jfQK+1vh+EN5bPdXNG/jK5X5ehRjPMlzGLXvNZ40p?= =?us-ascii?Q?9YK2gp5t3JFJXdX8CaJPLZwqWJ9v3Ir3lFvfiIYViOX5OJ827N7ESPdEAks7?= =?us-ascii?Q?MsCmJ+627fUNVrftEeK0qjOWnrVmf76dBJjk2UJmJM9umzizcxh5A8YzPbKA?= =?us-ascii?Q?1WUg9ZXFyoxy0sFG5PslXaeCVWa/ezWcpMW5u1DdlGwfE2WgSezSNbsLpP2s?= =?us-ascii?Q?nXgFXPUlU6+8CSSRl9O4ZjmnxZFANpDZeXf7wUbFdrqZsF3SMVaIXDwRrkdl?= =?us-ascii?Q?zOTtEYcltxpSw3GfAz3LWaKKtD9qv8gtFnbJocB8PxLRCRFmOsxb2bbg3O6q?= =?us-ascii?Q?/BVACYUSZbwHOpw3HD161/WwswvN3F7DF0L4EK+wH53bTBMnMFxZ92DKnk+W?= =?us-ascii?Q?IdtYTvBcD/hIHKKIMUt+5H7OMG+9FOSTklxUhTEqOzBFwBZSZoAJQlEf7cnD?= =?us-ascii?Q?tqTbWbT/IyaawhrzUSFBBCahA6KdpYdW4l0435JsUcw5/aO0h1TCdDfsvPtD?= =?us-ascii?Q?5bc1YL+cP+nV/rGZMdNJjvzhmpBpNQbc1zwVhHwbl2f47uHBRxsQ3ndFE0hM?= =?us-ascii?Q?/dbEjktH3S2HL5SCGTWbwhpRXUAupAR3B7l0QpBzan6G0SvGB/ivN9f1rh9p?= =?us-ascii?Q?UivaXo0IUENHt2uA3QUrPfTHQaxrg7lTmGT2bSIw2kMFngwBx33xRQoAnkqG?= =?us-ascii?Q?ChmiQXvLqDpY50DfDxgqoCOwsxYGrQqCWilFFPITZP84X2dl6bZioD7cRbp/?= =?us-ascii?Q?f2Ecy+QCaz360bt1MFtgMtgzgl07lz2HtCP/NuQN?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SA1PR11MB5801.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 55c80fdb-917e-44dd-e05e-08da8536093f X-MS-Exchange-CrossTenant-originalarrivaltime: 23 Aug 2022 18:33:55.5630 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: k5Xd7FlJSkHqD7XOGCdpuInTchv8ex5CeAvzpIIZWyYKzJ+1/eAQ31aJmilYKQJw6yQfe50KDmxcI6tMdkFxZg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN6PR11MB2544 Return-Path: isaac.w.oram@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Implementing this way will break the build for most of the open MinPlatform= ports. At minimum, please add the CompressLib to CoreCommonLib.dsc next t= o the UefiDecompressLib instantiation so that it is included automatically = for most boards. Regarding the design, I agree this is a good capability. And it makes sens= e to me to be board controlled rather than FSP controlled. I wonder if it might be better to modify the LargeVariableRead/Write such t= hat it compresses/decompresses large variables automatically. Could be con= trolled via library class instance or maybe via PatchablePerModule PCD. Bo= ards would still have a lot of control if they wanted. Regards, Isaac -----Original Message----- From: devel@edk2.groups.io On Behalf Of Michael Kuba= cki Sent: Monday, August 22, 2022 8:23 PM To: devel@edk2.groups.io Cc: Chiu, Chasel ; Desimone, Nathaniel L ; Oram, Isaac W ; Gao, Liming = ; Dong, Eric Subject: [edk2-devel] [edk2-platforms][PATCH v2 1/1] MinPlatformPkg: Add Fs= pNvsBuffer compression option From: Michael Kubacki Adds a PCD called "PcdEnableCompressedFspNvsBuffer" that allows the "FspNvs= Buffer" UEFI variable data to be saved as compressed data. Especially due to the nature of the data saved in this variable, it compres= ses well. For example, it has been found to reduce ~63KB of data to ~13KB. = Boot time impact has been found to be negligible. The default value is FALSE to keep default behavior consistent. Decompression can be performed on the variable data using the standard Uefi= DecompressLib. Cc: Chasel Chiu Cc: Nate DeSimone Cc: Isaac Oram Cc: Liming Gao Cc: Eric Dong Signed-off-by: Michael Kubacki --- Notes: v2: Rebase onto 9769bf28d1fc Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/SaveMemoryConfig= .c | 62 ++++++++++++++++---- Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/SaveMemoryConfig= .inf | 4 ++ Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec = | 6 ++ Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc = | 1 + 4 files changed, 60 insertions(+), 13 deletions(-) diff --git a/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/Save= MemoryConfig.c b/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/= SaveMemoryConfig.c index 0215e8eeddfb..95b8cef8b32b 100644 --- a/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/SaveMemoryC= onfig.c +++ b/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/SaveMemo +++ ryConfig.c @@ -3,6 +3,7 @@ exists, and saves the data to nvRAM. =20 Copyright (c) 2017 - 2022, Intel Corporation. All rights reserved.
+Copyright (c) Microsoft Corporation.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -10,6 +11,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include #include +#include #include #include #include @@ -19,6 +21,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include #include #includ= e +#include #include #include =20 @@ -38,20 +41,26 @@ SaveMemoryConfigEntryPoint ( IN EFI_SYSTEM_TABLE *SystemTable ) { - EFI_STATUS Status; - EFI_HOB_GUID_TYPE *GuidHob; - VOID *HobData; - VOID *VariableData; - UINTN DataSize; - UINTN BufferSize; - BOOLEAN DataIsIdentical; + EFI_STATUS Status; + EFI_HOB_GUID_TYPE *GuidHob; + VOID *HobData; + VOID *VariableData; + UINTN DataSize; + UINTN BufferSize; + BOOLEAN DataIsIdentical; + VOID *CompressedData; + UINT64 CompressedSize; + UINTN CompressedAllocationPages; =20 - DataSize =3D 0; - BufferSize =3D 0; - VariableData =3D NULL; - GuidHob =3D NULL; - HobData =3D NULL; - DataIsIdentical =3D FALSE; + DataSize =3D 0; + BufferSize =3D 0; + VariableData =3D NULL; + GuidHob =3D NULL; + HobData =3D NULL; + DataIsIdentical =3D FALSE; + CompressedData =3D NULL; + CompressedSize =3D 0; + CompressedAllocationPages =3D 0; =20 // // Search for the Memory Configuration GUID HOB. If it is not present, = then @@ -73,6 +82,29 @@ SaveMemoryConfigEntryPoint ( } } =20 + if (PcdGetBool (PcdEnableCompressedFspNvsBuffer)) { + if (DataSize > 0) { + CompressedAllocationPages =3D EFI_SIZE_TO_PAGES (DataSize); + CompressedData =3D AllocatePages (CompressedAllocationPag= es); + if (CompressedData =3D=3D NULL) { + DEBUG ((DEBUG_ERROR, "[%a] - Failed to allocate compressed data bu= ffer.\n", __FUNCTION__)); + ASSERT_EFI_ERROR (EFI_OUT_OF_RESOURCES); + return EFI_OUT_OF_RESOURCES; + } + + CompressedSize =3D EFI_PAGES_TO_SIZE (CompressedAllocationPages); + Status =3D Compress (HobData, DataSize, CompressedData, &Com= pressedSize); + if (EFI_ERROR (Status)) { + DEBUG ((DEBUG_ERROR, "[%a] - failed to compress data. Status =3D %= r\n", __FUNCTION__, Status)); + ASSERT_EFI_ERROR (Status); + return Status; + } + } + + HobData =3D CompressedData; + DataSize =3D (UINTN)CompressedSize; + } + if (HobData !=3D NULL) { DEBUG ((DEBUG_INFO, "FspNvsHob.NvsDataLength:%d\n", DataSize)); DEBUG ((DEBUG_INFO, "FspNvsHob.NvsDataPtr : 0x%x\n", HobData)); @@ -136,6 +168,10 @@ SaveMemoryConfigEntryPoint ( DEBUG((DEBUG_ERROR, "Memory S3 Data HOB was not found\n")); } =20 + if (CompressedData !=3D NULL) { + FreePages (CompressedData, CompressedAllocationPages); } + // // This driver does not produce any protocol services, so always unload = it. // diff --git a/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/Save= MemoryConfig.inf b/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfi= g/SaveMemoryConfig.inf index 61e85a658693..0f12deb131ca 100644 --- a/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/SaveMemoryC= onfig.inf +++ b/Platform/Intel/MinPlatformPkg/FspWrapper/SaveMemoryConfig/SaveMemo +++ ryConfig.inf @@ -26,6 +26,7 @@ [LibraryClasses] LargeVariableReadLib LargeVariableWriteLib BaseLib + CompressLib =20 [Packages] MdePkg/MdePkg.dec @@ -45,6 +46,9 @@ [Guids] gFspNonVolatileStorageHob2Guid ## CONSUMES gFspNvsBufferVariableGuid ## PRODUCES =20 +[Pcd] + gMinPlatformPkgTokenSpaceGuid.PcdEnableCompressedFspNvsBuffer + [Depex] gEfiVariableArchProtocolGuid AND gEfiVariableWriteArchProtocolGuid \ No newline at end of file diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec b/Platform/In= tel/MinPlatformPkg/MinPlatformPkg.dec index 8e603b7bf94b..94353cb76824 100644 --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec @@ -306,6 +306,12 @@ [PcdsFixedAtBuild, PcdsPatchableInModule, PcdsDynamic,= PcdsDynamicEx] =20 gMinPlatformPkgTokenSpaceGuid.PcdPlatformMemoryCheckLevel|0|UINT32|0x300= 00009 =20 + ## Controls whether the FSP NVS buffer is saved as compressed data. + # Data compression can significantly reduce variable storage usage for F= SP NVS buffer data. + # Platforms that choose to compress the data will need to decompress=20 + the variable data upon # extraction. + =20 + gMinPlatformPkgTokenSpaceGuid.PcdEnableCompressedFspNvsBuffer|FALSE|BO + OLEAN|0x30000010 + ## This PCD is to control which device is the potential trusted console = input device.

# For example:
# USB Short Form: UsbHID(0xFFFF,0xFFFF,0x1,0x1)
diff --git a/Platfor= m/Intel/MinPlatformPkg/MinPlatformPkg.dsc b/Platform/Intel/MinPlatformPkg/M= inPlatformPkg.dsc index 09aa6fe4d51c..ae170f87d548 100644 --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc @@ -106,6 +106,7 @@ [LibraryClasses.common.DXE_DRIVER] FspWrapperPlatformLib|MinPlatformPkg/FspWrapper/Library/DxeFspWrapperPla= tformLib/DxeFspWrapperPlatformLib.inf TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/DxeTestP= ointCheckLib.inf TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/DxeTestPointLib.in= f + CompressLib|MinPlatformPkg/Library/CompressLib/CompressLib.inf =20 [LibraryClasses.common.DXE_SMM_DRIVER] TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/SmmTestP= ointCheckLib.inf -- 2.28.0.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D Groups.io Links: You receive all messages sent to this group. View/Reply Online (#92644): https://edk2.groups.io/g/devel/message/92644 Mute This Topic: https://groups.io/mt/93197638/1492418 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [isaac.w.oram@intel.com] -=3D-=3D-=3D-=3D-=3D-=3D