From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by mx.groups.io with SMTP id smtpd.web08.32578.1658176204193230506 for ; Mon, 18 Jul 2022 13:30:04 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="unable to parse pub key" header.i=@intel.com header.s=intel header.b=Uubq5ve1; spf=pass (domain: intel.com, ip: 192.55.52.151, mailfrom: chasel.chiu@intel.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1658176204; x=1689712204; h=from:to:subject:date:message-id:references:in-reply-to: content-transfer-encoding:mime-version; bh=A+9o2E8Sa+3gibbA6+4qf+P4qU7EbIOh+d5TGTG4a4E=; b=Uubq5ve1B19RhHDL6qi0KVN94LYpemR5sHGBCBErO61znaa8Tr7IqMXr SOhFpCZNT1iSGLilTv3sz++MJxnh4KIbUlfepdtSVNc0Ve2ffR0S1H1R2 ycseslzIwcjXoGt/Gz42GmUArlw+fY7aur8YjbzBqkSjY66Fs/jDudcm6 RxBxwXPk11Alu6lvXGr9yg8KUBob/sNcFNcca1wdzyfG0YAFLbqwOCiMV r4PbPJVfm350BhFOYvKTqmUJlpBu0aRUChcKvz3lc0+5YSmtRgXwII8to vM0tDIoXn5E0ziUba7POjYxLPB3FWfvHx/3YjHd9AmHOE68WOkPF2YDqz Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10412"; a="266720076" X-IronPort-AV: E=Sophos;i="5.92,282,1650956400"; d="scan'208";a="266720076" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Jul 2022 13:30:03 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.92,282,1650956400"; d="scan'208";a="723989678" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by orsmga004.jf.intel.com with ESMTP; 18 Jul 2022 13:30:03 -0700 Received: from orsmsx601.amr.corp.intel.com (10.22.229.14) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28; Mon, 18 Jul 2022 13:30:03 -0700 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx601.amr.corp.intel.com (10.22.229.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.28 via Frontend Transport; Mon, 18 Jul 2022 13:30:02 -0700 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (104.47.59.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.2308.27; Mon, 18 Jul 2022 13:30:02 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hu9RNtjO5hWK5zXSRVtxWO9WX+jfKbbS0hfgiV4/E1ynObQlyOPLKhSZxxRoxin2gtzifR8oTnw+CEvRsK1PVv9WzT/B6oF7D3u4FDEc2B9NNI712lDS2c/LB5kO1lTECIleqdYZjzv5cy+NzYNxYS9xT7s/5VoVe5Q0mA67gYGxFySfiiu7Hq97w8s+HWiq6JPmKZDehH/SM9/biOVr5YFcW7y0ucWvBQXxsAiGUmHOl5x8aw4uoJY4r0Te9j4CIgKGC96IQ43z2/9cN6FE7DmUaXgEe3+g2e7TdsPnWK1s352VCf17fR4RVEgoA635ezrZk86844rNxLDxVT+P8A== 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=6Q86s4cNxkXNTrpdoI+ZUoR7ksDKaGoUOzDM4ti9lwc=; b=FnT5o47F2TuF/io2wnfV3EQSJVe0itK+bBMF7tbsPZpoOff2WnrazbpOuZrXfzv/mYP/9iRAW/cpQeP/sm12HRBbhu96xhm4dh/8UV6MUJDji3CFva+W7raAi081WD2hNFFQpXkClxxw8hhSfNyZHKxi61XTKd2j6DGSUNJU/yxf/yFs5nRTNxmQcT/x1KOa1bpcuON8Jz71RhhZTwG42IgEKNha+gDnjhV71IEFThyBo+WsatknjxsMlyzEvd1KdMrGz3xfkZ37agVUZ+9N/YvcTk0ZHUmIKjIIGUVxZp+j1Dg1SPyFksiXHi7TDWGnGHD3FLTPW96b7XXLrWw9Nw== 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 BN9PR11MB5483.namprd11.prod.outlook.com (2603:10b6:408:104::10) by DM6PR11MB3003.namprd11.prod.outlook.com (2603:10b6:5:71::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5438.20; Mon, 18 Jul 2022 20:30:01 +0000 Received: from BN9PR11MB5483.namprd11.prod.outlook.com ([fe80::a113:c892:d94:dd10]) by BN9PR11MB5483.namprd11.prod.outlook.com ([fe80::a113:c892:d94:dd10%8]) with mapi id 15.20.5438.023; Mon, 18 Jul 2022 20:30:01 +0000 From: "Chiu, Chasel" To: "Desimone, Nathaniel L" , "devel@edk2.groups.io" Subject: Re: [PATCH V1] IntelFsp2Pkg: Add Definition of EDKII_PEI_VARIABLE_PPI Thread-Topic: [PATCH V1] IntelFsp2Pkg: Add Definition of EDKII_PEI_VARIABLE_PPI Thread-Index: AQHYmuNsVlj8saHeyEaqEWHdb04Tqq2ElHYA Date: Mon, 18 Jul 2022 20:30:01 +0000 Message-ID: References: <20220718201725.5017-1-nathaniel.l.desimone@intel.com> In-Reply-To: <20220718201725.5017-1-nathaniel.l.desimone@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.6.500.17 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: a2593a4a-4062-40a5-a8b0-08da68fc4a21 x-ms-traffictypediagnostic: DM6PR11MB3003:EE_ x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: 17P/kjAKVYbc2CH7J0bXFREuX3h0B9ucYcp4poW+9aSduXL9OlVKTpmD3KIkhCpEszJlbbLU9868yrwkREoU46UY7CVKH2+5g4qOLI6mvigUkTUkUnR5hQcs0KBFWW5A/jDKjg55Nh1ihLmBivLjdJbY72kiX3Ris8shj1C2AaNrNiwyRf7FQPsYkcwfBo2jWR4bv3Yfms+dNqt/rgWebaMKV0fAoucTEYXo9fbYtqWRjqfuPUzQqWTpUMITXsExc9YWODO3VJHkAEkJrFfbGVWjHqq9Bcc+/b7ojIp6GEWJKeVmny6hTZiYYDhgfhzK6bQf6JWqURIIa2rHMU0DDYfPIgff40nK8SAdAd6l+IiN74xNIi86mAIaaqmRyi1TP6+Yaql7c5wx1GZUXlOtgYFLW5lmGikWnSaUrWRlCZ9/zf//ctIMbQznG8LyFBgS7bjfrd0KVqzO6H8tY0BrgmSyyVeqVJU+TfkLzCgQ9El6gBCTrOJfnGta0BZtBy9CbXl2vZ9XBCmZt+EBw2r5vA6pvE3fM2m2FWHxg/olVEYwFyD6plCF3cKXHpRvh00Xzz6y9mkc6M0h9EDIPgZt19NItaNqCTvqsLrj73nECsVBf8R3caILD/+Ho3rtAgREBU/PhkMXOntrnAj6Xnr2S4CPyksmW7LbCa7RVlWg0kQULU04cLAHbl8x0pl17iId9PYOrVi0rYSCA+3nsebTa5vtKzp8WvD3jTa009EiSd1HSxhtBlIMKCuzrPMDG9qc2hRSAsbn7xNfZI/Emxf1yoX+Bn2ijmv9H26dEhIcnD+VLfgQubprgQVjtgoijp2i x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN9PR11MB5483.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(366004)(39860400002)(346002)(376002)(136003)(396003)(38100700002)(86362001)(38070700005)(82960400001)(33656002)(6506007)(19627235002)(186003)(478600001)(30864003)(7696005)(71200400001)(9686003)(41300700001)(53546011)(110136005)(26005)(2906002)(64756008)(66556008)(66476007)(66946007)(316002)(52536014)(66446008)(8936002)(5660300002)(76116006)(55016003)(8676002)(122000001)(83380400001);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?zOTSHUO5O2aG9KG241XZGA/gQr02eImWc/Ku+r3tKrH+II7jonAhhNw8sdRl?= =?us-ascii?Q?KO9AKPfUOe0uw/GxnKL3EZq5A9fJJ/hS2nSM9t5WY8dQ1ls+bZP8aq43JhmL?= =?us-ascii?Q?wmb8lJ3VX9IgmneHjBXILTOvgzP+YcHVJKdz6s5MpQBR4aapz64vRoS3/4zh?= =?us-ascii?Q?s3qxPLhZ5srp4GWBa9n5GMxcEazTLXcw/deuqKl1Tt9L77oyMwGW77i4Rvoe?= =?us-ascii?Q?HCeZu8eNE9EzxQ01uSS5GcQzrfdrRWNgJg3JC5Vm6WHVl/tG7X2SxOsAW3Bq?= =?us-ascii?Q?V0DrjP22BGSoIrYM0HIrdRTQo0tMaIZDk0U8DcNDa2AkDPHvWMMM1DPhS92H?= =?us-ascii?Q?dnordArejykWlH7m018+EF2e1rCgSy6KPGlcNsoQvHzKrh/kOxsciGuRKN67?= =?us-ascii?Q?fQtqFtUZ91KerXqBltqMuEnIg9py0XecRH97NGt7NElc6dQcL3EEDcuPGgBg?= =?us-ascii?Q?GiAmwGiOkfYff0iI8MUydgqN4J4JcQkJZMyjsFNz2f36+t3s1U1mk0U6hqAJ?= =?us-ascii?Q?fPNaXH0kxNg4K475Cu2+/buhcvttx1pJwesh+SsqrGzGIzTTQp5Ye74nk3PS?= =?us-ascii?Q?5LgmRqowbCOIEWYNn++PTCLzqqYHAMyWy6Z0kniZ3TqUzHnS1zylMhY9wGeU?= =?us-ascii?Q?j9dguKkx0gxSoznyAO1LMNGy1PCTdS2f2Zm2HbQceSg456hdGbEbL2B4YaKn?= =?us-ascii?Q?258qIodTZm5GIkpi+UgxyUqGGneoxMY6Lv+i1Qo0yyUZDq0C/BfZgMxG5y56?= =?us-ascii?Q?vKD4ML6STOwDCLoHRma2loUWOFF4NNw5zD51Zhw+EI1LlGdapTz8T1uuQhod?= =?us-ascii?Q?PH+37thslExNUK3qYTAugqfJVdZFPjVh4W4nkjg8xGZve/K/R4Ir9ps3wpQQ?= =?us-ascii?Q?FnMqQCLsRGjVBEmc0pivbjklPTwZvbbIPW8heh+E2PBT2wF0TbWgtJXW5IKt?= =?us-ascii?Q?T+ZNryG9tCE6JWjTcrM9R3GNAhPxBt0+ElRYbid2TGD84WU2dUUaxX5Dxhvu?= =?us-ascii?Q?zKNOHkSF97ji1UMCCjXDCgAKqwJhQLp4nhoziu/qZe5pYdIC2driqB2qQtma?= =?us-ascii?Q?x12psu8ZIdFN9+57O+P8+oJ3FpfGaeyV2mMZ2PuPfWHGnoxbSabXd3AgU0jv?= =?us-ascii?Q?ycST7dal35flQ43iy2BWxFbjq12z52v/110hbOmyOgOq61YN2rv+iFSSnLR8?= =?us-ascii?Q?d2meb4K5f1F02T105VQo+e0LwsN3DHOORtkGTd6Jh3Gss0ZEHCZeUfq5dYcc?= =?us-ascii?Q?hDvS/yw4q4UDzv8EIWT07RVB56wP9yDEEeDCVg1FQyO4Xn0Z4OuCU0atFua/?= =?us-ascii?Q?roGPrdX3t6AhmoCQRTecDHE9whCOJUvxiDqpP7/CL1Ej32V4G47vt5n9z2GI?= =?us-ascii?Q?TxbiNZQ9wvXb5fOiNBZzd/SRvYVjZET75FU9lwJY2sBrtux3pU1ViYChQ1sd?= =?us-ascii?Q?/rdpt1VKkdSrdwcIzndCsMM197BgFA2TqakJc7EOWdV9uPR0g+tmN17+nvb8?= =?us-ascii?Q?U1E+64jCIsX9HnWe69x8LiO+ZJo0L75a2pazLe9tMyI6Cp93swML+EZurRlE?= =?us-ascii?Q?5ebWb0cPSfsOD+VFas3vWBmNVnWX4ZK9fG1YWOsH?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BN9PR11MB5483.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: a2593a4a-4062-40a5-a8b0-08da68fc4a21 X-MS-Exchange-CrossTenant-originalarrivaltime: 18 Jul 2022 20:30:01.0957 (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: FEYpT6qrS4TXbTl/B8JHTAjI+ebVJRlgCsBlad1zhTPPIzp7KQa1DijFRx60z7Q5HpHNfxKNJmMUOvtleF5XRw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB3003 Return-Path: chasel.chiu@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Chasel Chiu Thanks, Chasel > -----Original Message----- > From: Desimone, Nathaniel L > Sent: Monday, July 18, 2022 1:17 PM > To: devel@edk2.groups.io > Cc: Chiu, Chasel > Subject: [PATCH V1] IntelFsp2Pkg: Add Definition of EDKII_PEI_VARIABLE_PP= I >=20 > Adds definition of EDKII_PEI_VARIABLE_PPI. >=20 > Cc: Chasel Chiu > Signed-off-by: Nate DeSimone > --- > IntelFsp2Pkg/Include/Ppi/Variable.h | 195 ++++++++++++++++++++++++++++ > IntelFsp2Pkg/IntelFsp2Pkg.dec | 8 +- > 2 files changed, 202 insertions(+), 1 deletion(-) create mode 100644 > IntelFsp2Pkg/Include/Ppi/Variable.h >=20 > diff --git a/IntelFsp2Pkg/Include/Ppi/Variable.h > b/IntelFsp2Pkg/Include/Ppi/Variable.h > new file mode 100644 > index 0000000000..3e1f4b98a9 > --- /dev/null > +++ b/IntelFsp2Pkg/Include/Ppi/Variable.h > @@ -0,0 +1,195 @@ > +/** @file > + EDKII PEI Variable PPI provides an implementation of variables > + intended for use as a means to store data in the PEI environment. > + > + Copyright (c) 2022, Intel Corporation. All rights reserved.
> + SPDX-License-Identifier: BSD-2-Clause-Patent > + > +**/ > + > +#ifndef EDKII_PEI_VARIABLE_PPI_H_ > +#define EDKII_PEI_VARIABLE_PPI_H_ > + > +#define EDKII_PEI_VARIABLE_PPI_GUID \ > + { \ > + 0xe7b2cd04, 0x4b14, 0x44c2, { 0xb7, 0x48, 0xce, 0xaf, 0x2b, 0x66, > +0x4a, 0xb0 } \ > + } > + > +typedef struct _EDKII_PEI_VARIABLE_PPI EDKII_PEI_VARIABLE_PPI; > + > +/** > + This service retrieves a variable's value using its name and GUID. > + > + Read the specified variable from the UEFI variable store. If the Data > + buffer is too small to hold the contents of the variable, the error > + EFI_BUFFER_TOO_SMALL is returned and DataSize is set to the required > + buffer size to obtain the data. > + > + @param[in] This A pointer to this instance of the > EDKII_PEI_VARIABLE_PPI. > + @param[in] VariableName A pointer to a null-terminated str= ing that is > the variable's name. > + @param[in] VariableGuid A pointer to an EFI_GUID that is t= he variable's > GUID. The combination of > + VariableGuid and VariableName must= be unique. > + @param[out] Attributes If non-NULL, on return, points to = the > variable's attributes. > + @param[in, out] DataSize On entry, points to the size in by= tes of the > Data buffer. > + On return, points to the size of t= he data returned in Data. > + @param[out] Data Points to the buffer which will ho= ld the returned > variable value. > + May be NULL with a zero DataSize i= n order to determine > the size of the > + buffer needed. > + > + @retval EFI_SUCCESS The variable was read successfully= . > + @retval EFI_NOT_FOUND The variable was not found. > + @retval EFI_BUFFER_TOO_SMALL The DataSize is too small for the > resulting data. > + DataSize is updated with the size = required for > + the specified variable. > + @retval EFI_INVALID_PARAMETER VariableName, VariableGuid, DataSi= ze > or Data is NULL. > + @retval EFI_DEVICE_ERROR The variable could not be retrieve= d > because of a device error. > + > +**/ > +typedef > +EFI_STATUS > +(EFIAPI *EDKII_PEI_GET_VARIABLE)( > + IN CONST EDKII_PEI_VARIABLE_PPI *This, > + IN CONST CHAR16 *VariableName, > + IN CONST EFI_GUID *VariableGuid, > + OUT UINT32 *Attributes OPTIONAL, > + IN OUT UINTN *DataSize, > + OUT VOID *Data OPTIONAL > + ); > + > +/** > + Return the next variable name and GUID. > + > + This function is called multiple times to retrieve the VariableName > + and VariableGuid of all variables currently available in the system. > + On each call, the previous results are passed into the interface, > + and, on return, the interface returns the data for the next variable. > + To get started, VariableName should initially contain L"\0" > + and VariableNameSize should be sizeof(CHAR16). When the entire > + variable list has been returned, EFI_NOT_FOUND is returned. > + > + @param[in] This A pointer to this instance of the > EDKII_PEI_VARIABLE_PPI. > + @param[in, out] VariableNameSize On entry, points to the size of th= e buffer > pointed to by VariableName. > + On return, the size of the variabl= e name buffer. > + @param[in, out] VariableName On entry, a pointer to a null-term= inated > string that is the variable's name. > + On return, points to the next vari= able's null-terminated > name string. > + @param[in, out] VariableGuid On entry, a pointer to an EFI_GUID= that is > the variable's GUID. > + On return, a pointer to the next v= ariable's GUID. > + > + @retval EFI_SUCCESS The next variable name was read su= ccessfully. > + @retval EFI_NOT_FOUND All variables have been enumerated= . > + @retval EFI_BUFFER_TOO_SMALL The VariableNameSize is too small = for > the resulting > + data. VariableNameSize is updated = with the size > + required for the specified variabl= e. > + @retval EFI_INVALID_PARAMETER VariableName, VariableGuid or > + VariableNameSize is NULL. > + @retval EFI_DEVICE_ERROR The variable could not be retrieve= d > because of a device error. > + > +**/ > +typedef > +EFI_STATUS > +(EFIAPI *EDKII_PEI_GET_NEXT_VARIABLE_NAME)( > + IN CONST EDKII_PEI_VARIABLE_PPI *This, > + IN OUT UINTN *VariableNameSize, > + IN OUT CHAR16 *VariableName, > + IN OUT EFI_GUID *VariableGuid > + ); > + > +/** > + Sets the value of a variable. > + > + @param[in] This A pointer to this instance of the > EDKII_PEI_VARIABLE_PPI. > + @param[in] VariableName A Null-terminated string that is t= he name of > the vendor's variable. > + Each VariableName is unique for ea= ch VendorGuid. > VariableName must > + contain 1 or more characters. If V= ariableName is an empty > string, > + then EFI_INVALID_PARAMETER is retu= rned. > + @param[in] VendorGuid A unique identifier for the vendor= . > + @param[in] Attributes Attributes bitmask to set for the = variable. > + @param[in] DataSize The size in bytes of the Data buff= er. Unless the > EFI_VARIABLE_APPEND_WRITE > + attribute is set, a size of zero c= auses the variable to be > deleted. When the > + EFI_VARIABLE_APPEND_WRITE attribut= e is set, then a > SetVariable() call with a > + DataSize of zero will not cause an= y change to the variable > value. > + @param[in] Data The contents for the variable. > + > + @retval EFI_SUCCESS The firmware has successfully stor= ed the > variable and its data as > + defined by the Attributes. > + @retval EFI_INVALID_PARAMETER An invalid combination of attribut= e bits, > name, and GUID was supplied, or the > + DataSize exceeds the maximum allow= ed. > + @retval EFI_INVALID_PARAMETER VariableName is an empty string. > + @retval EFI_OUT_OF_RESOURCES Not enough storage is available to= hold > the variable and its data. > + @retval EFI_DEVICE_ERROR The variable could not be stored d= ue to a > hardware error. > + @retval EFI_WRITE_PROTECTED The variable in question is read-o= nly. > + @retval EFI_WRITE_PROTECTED The variable in question cannot be > deleted. > + @retval EFI_SECURITY_VIOLATION The variable could not be written = due > to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, > + or > EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS, or > + EFI_VARIABLE_ENHANCED_AUTHENTICATE= D_ACCESS > being set. Writing to authenticated > + variables is not supported in the = PEI environment. Updates > to authenticated > + variables can be requested during = PEI via the > EFI_AUTHENTICATED_VARIABLE_HOB, but > + these updates won't be written to = non-volatile storage > until later in DXE. > + The EFI_AUTHENTICATED_VARIABLE_HOB= is a HOB with > the GUID > + gEfiAuthenticatedVariableGuid. Thi= s HOB contains a > VARIABLE_STORE_HEADER followed > + by one or more UEFI variables, whi= ch are stored as > DWORD aligned tuples of > + (VARIABLE_HEADER + CHAR16 Variable= Name + > VariableData). > + See MdeModulePkg/Include/Guid/Vari= ableFormat.h for > these data structure > + definitions and > MdeModulePkg/Universal/Variable/RuntimeDxe/VariableParsing.c for > + an example of how to parse these d= ata structures. > + @retval EFI_NOT_FOUND The variable trying to be updated = or deleted > was not found. > + > +**/ > +typedef > +EFI_STATUS > +(EFIAPI *EDKII_PEI_SET_VARIABLE)( > + IN CONST EDKII_PEI_VARIABLE_PPI *This, > + IN CHAR16 *VariableName, > + IN EFI_GUID *VendorGuid, > + IN UINT32 Attributes, > + IN UINTN DataSize, > + IN VOID *Data > + ); > + > +/** > + Returns information about the UEFI variables. > + > + @param[in] This A pointer to this inst= ance of the > EDKII_PEI_VARIABLE_PPI. > + @param[in] Attributes Attributes bitmask to = specify the type of > variables on > + which to return inform= ation. > + @param[out] MaximumVariableStorageSize On output the maximum = size > of the storage space > + available for the EFI = variables associated with the > + attributes specified. > + @param[out] RemainingVariableStorageSize Returns the remaining = size of > the storage space > + available for the EFI = variables associated with the > + attributes specified. > + @param[out] MaximumVariableSize Returns the maximum si= ze of > the individual EFI > + variables associated w= ith the attributes specified. > + > + @retval EFI_SUCCESS Valid answer returned. > + @retval EFI_INVALID_PARAMETER An invalid combination= of > attribute bits was supplied > + @retval EFI_UNSUPPORTED The attribute is not s= upported on > this platform, and the > + MaximumVariableStorage= Size, > + RemainingVariableStora= geSize, > MaximumVariableSize > + are undefined. > + > +**/ > +typedef > +EFI_STATUS > +(EFIAPI *EDKII_PEI_QUERY_VARIABLE_INFO)( > + IN CONST EDKII_PEI_VARIABLE_PPI *This, > + IN UINT32 Attributes, > + OUT UINT64 *MaximumVariableStorageSize, > + OUT UINT64 *RemainingVariableStorageSize, > + OUT UINT64 *MaximumVariableSize > + ); > + > +/// > +/// PEI Variable PPI is intended for use as a means /// to store data > +in the PEI environment. > +/// > +struct _EDKII_PEI_VARIABLE_PPI { > + EDKII_PEI_GET_VARIABLE GetVariable; > + EDKII_PEI_GET_NEXT_VARIABLE_NAME GetNextVariableName; > + EDKII_PEI_SET_VARIABLE SetVariable; > + EDKII_PEI_QUERY_VARIABLE_INFO QueryVariableInfo; > +}; > + > +extern EFI_GUID gEdkiiPeiVariablePpiGuid; > + > +#endif > diff --git a/IntelFsp2Pkg/IntelFsp2Pkg.dec b/IntelFsp2Pkg/IntelFsp2Pkg.de= c index > 58eac7220d..2d3eb708b9 100644 > --- a/IntelFsp2Pkg/IntelFsp2Pkg.dec > +++ b/IntelFsp2Pkg/IntelFsp2Pkg.dec > @@ -1,7 +1,7 @@ > ## @file > # Provides driver and definitions to build fsp in EDKII bios. > # > -# Copyright (c) 2014 - 2021, Intel Corporation. All rights reserved.
> +# Copyright (c) 2014 - 2022, Intel Corporation. All rights > +reserved.
> # SPDX-License-Identifier: BSD-2-Clause-Patent # ## @@ -59,6 +59,12 @@ > # > gFspTempRamExitPpiGuid =3D { 0xbc1cfbdb, 0x7e50, 0x42be= , {0xb4, > 0x87, 0x22, 0xe0, 0xa9, 0x0c, 0xb0, 0x52}} >=20 > + # > + # PPI for Variable Services > + # > + gEdkiiPeiVariablePpiGuid =3D { 0xe7b2cd04, 0x4b14, 0x44c2= , {0xb7, 0x48, > 0xce, 0xaf, 0x2b, 0x66, 0x4a, 0xb0}} > + > + > [Guids] > # > # GUID defined in package > -- > 2.27.0.windows.1