--- /dev/null
+/** @file\r
+ This PPI is installed by the platform PEIM to designate that a recovery boot \r
+ is in progress.\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: BootInRecoveryMode.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+\r
+**/\r
+\r
+#ifndef __BOOT_IN_RECOVERY_MODE_PPI_H__\r
+#define __BOOT_IN_RECOVERY_MODE_PPI_H__\r
+\r
+#define EFI_PEI_BOOT_IN_RECOVERY_MODE_PEIM_PPI \\r
+ { \\r
+ 0x17ee496a, 0xd8e4, 0x4b9a, {0x94, 0xd1, 0xce, 0x82, 0x72, 0x30, 0x8, 0x50 } \\r
+ }\r
+\r
+\r
+extern EFI_GUID gEfiPeiBootInRecoveryModePpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares CPU IO PPI that abstracts CPU IO access\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: CpuIo.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+ \r
+**/\r
+\r
+#ifndef __PEI_CPUIO_PPI_H__\r
+#define __PEI_CPUIO_PPI_H__\r
+\r
+#define EFI_PEI_CPU_IO_PPI_INSTALLED_GUID \\r
+ { 0xe6af1f7b, 0xfc3f, 0x46da, {0xa8, 0x28, 0xa3, 0xb4, 0x57, 0xa4, 0x42, 0x82 } }\r
+\r
+typedef struct _EFI_PEI_CPU_IO_PPI EFI_PEI_CPU_IO_PPI;\r
+\r
+//\r
+// *******************************************************\r
+// EFI_PEI_CPU_IO_PPI_WIDTH\r
+// *******************************************************\r
+//\r
+typedef enum {\r
+ EfiPeiCpuIoWidthUint8,\r
+ EfiPeiCpuIoWidthUint16,\r
+ EfiPeiCpuIoWidthUint32,\r
+ EfiPeiCpuIoWidthUint64,\r
+ EfiPeiCpuIoWidthFifoUint8,\r
+ EfiPeiCpuIoWidthFifoUint16,\r
+ EfiPeiCpuIoWidthFifoUint32,\r
+ EfiPeiCpuIoWidthFifoUint64,\r
+ EfiPeiCpuIoWidthFillUint8,\r
+ EfiPeiCpuIoWidthFillUint16,\r
+ EfiPeiCpuIoWidthFillUint32,\r
+ EfiPeiCpuIoWidthFillUint64,\r
+ EfiPeiCpuIoWidthMaximum\r
+} EFI_PEI_CPU_IO_PPI_WIDTH;\r
+\r
+/**\r
+ Memory-based access services and I/O-based access services.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Width The width of the access. Enumerated in bytes.\r
+ @param Address The physical address of the access.\r
+ @param Count The number of accesses to perform.\r
+ @param Buffer A pointer to the buffer of data.\r
+\r
+ @retval EFI_SUCCESS The function completed successfully.\r
+ @retval EFI_NOT_YET_AVAILABLE The service has not been installed.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_MEM) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN EFI_PEI_CPU_IO_PPI_WIDTH Width,\r
+ IN UINT64 Address,\r
+ IN UINTN Count,\r
+ IN OUT VOID *Buffer\r
+ );\r
+\r
+//\r
+// *******************************************************\r
+// EFI_PEI_CPU_IO_PPI_ACCESS\r
+// *******************************************************\r
+//\r
+typedef struct {\r
+ EFI_PEI_CPU_IO_PPI_IO_MEM Read;\r
+ EFI_PEI_CPU_IO_PPI_IO_MEM Write;\r
+} EFI_PEI_CPU_IO_PPI_ACCESS;\r
+\r
+/**\r
+ 8-bit I/O read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT8\r
+\r
+**/\r
+typedef\r
+UINT8\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_READ8) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 16-bit I/O read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT16\r
+\r
+**/\r
+typedef\r
+UINT16\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_READ16) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 32-bit I/O read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT32\r
+\r
+**/\r
+typedef\r
+UINT32\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_READ32) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 64-bit I/O read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT64\r
+\r
+**/\r
+typedef\r
+UINT64\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_READ64) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 8-bit I/O write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_WRITE8) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT8 Data\r
+ );\r
+\r
+/**\r
+ 16-bit I/O write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_WRITE16) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT16 Data\r
+ );\r
+\r
+/**\r
+ 32-bit I/O write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_WRITE32) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT32 Data\r
+ );\r
+\r
+/**\r
+ 64-bit I/O write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_IO_WRITE64) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT64 Data\r
+ );\r
+\r
+/**\r
+ 8-bit Memory read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT8\r
+\r
+**/\r
+typedef\r
+UINT8\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_READ8) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 16-bit Memory read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT16\r
+\r
+**/\r
+typedef\r
+UINT16\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_READ16) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 32-bit Memory read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT32\r
+\r
+**/\r
+typedef\r
+UINT32\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_READ32) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 64-bit Memory read operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+\r
+ @return UINT64\r
+\r
+**/\r
+typedef\r
+UINT64\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_READ64) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address\r
+ );\r
+\r
+/**\r
+ 8-bit Memory write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_WRITE8) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT8 Data\r
+ );\r
+\r
+/**\r
+ 16-bit Memory write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_WRITE16) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT16 Data\r
+ );\r
+\r
+/**\r
+ 32-bit Memory write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_WRITE32) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT32 Data\r
+ );\r
+\r
+/**\r
+ 64-bit Memory write operations.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+ @param This Pointer to local data for the interface.\r
+ @param Address The physical address of the access.\r
+ @param Data The data to write.\r
+\r
+ @return None\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *EFI_PEI_CPU_IO_PPI_MEM_WRITE64) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_CPU_IO_PPI *This,\r
+ IN UINT64 Address,\r
+ IN UINT64 Data\r
+ );\r
+\r
+/**\r
+ @par Ppi Description:\r
+ EFI_PEI_CPU_IO_PPI provides a set of memory and I/O-based services.\r
+ The perspective of the services is that of the processor, not the bus or system.\r
+\r
+ @param Mem\r
+ Collection of memory-access services.\r
+\r
+ @param I/O\r
+ Collection of I/O-access services.\r
+\r
+ @param IoRead8\r
+ 8-bit read service.\r
+\r
+ @param IoRead16\r
+ 16-bit read service.\r
+\r
+ @param IoRead32\r
+ 32-bit read service.\r
+\r
+ @param IoRead64\r
+ 64-bit read service.\r
+\r
+ @param IoWrite8\r
+ 8-bit write service.\r
+\r
+ @param IoWrite16\r
+ 16-bit write service.\r
+\r
+ @param IoWrite32\r
+ 32-bit write service.\r
+\r
+ @param IoWrite64\r
+ 64-bit write service.\r
+\r
+ @param MemRead8\r
+ 8-bit read service.\r
+\r
+ @param MemRead16\r
+ 16-bit read service.\r
+\r
+ @param MemRead32\r
+ 32-bit read service.\r
+\r
+ @param MemRead64\r
+ 64-bit read service.\r
+\r
+ @param MemWrite8\r
+ 8-bit write service.\r
+\r
+ @param MemWrite16\r
+ 16-bit write service.\r
+\r
+ @param MemWrite32\r
+ 32-bit write service.\r
+\r
+ @param MemWrite64\r
+ 64-bit write service.\r
+\r
+**/\r
+struct _EFI_PEI_CPU_IO_PPI {\r
+ EFI_PEI_CPU_IO_PPI_ACCESS Mem;\r
+ EFI_PEI_CPU_IO_PPI_ACCESS Io;\r
+ EFI_PEI_CPU_IO_PPI_IO_READ8 IoRead8;\r
+ EFI_PEI_CPU_IO_PPI_IO_READ16 IoRead16;\r
+ EFI_PEI_CPU_IO_PPI_IO_READ32 IoRead32;\r
+ EFI_PEI_CPU_IO_PPI_IO_READ64 IoRead64;\r
+ EFI_PEI_CPU_IO_PPI_IO_WRITE8 IoWrite8;\r
+ EFI_PEI_CPU_IO_PPI_IO_WRITE16 IoWrite16;\r
+ EFI_PEI_CPU_IO_PPI_IO_WRITE32 IoWrite32;\r
+ EFI_PEI_CPU_IO_PPI_IO_WRITE64 IoWrite64;\r
+ EFI_PEI_CPU_IO_PPI_MEM_READ8 MemRead8;\r
+ EFI_PEI_CPU_IO_PPI_MEM_READ16 MemRead16;\r
+ EFI_PEI_CPU_IO_PPI_MEM_READ32 MemRead32;\r
+ EFI_PEI_CPU_IO_PPI_MEM_READ64 MemRead64;\r
+ EFI_PEI_CPU_IO_PPI_MEM_WRITE8 MemWrite8;\r
+ EFI_PEI_CPU_IO_PPI_MEM_WRITE16 MemWrite16;\r
+ EFI_PEI_CPU_IO_PPI_MEM_WRITE32 MemWrite32;\r
+ EFI_PEI_CPU_IO_PPI_MEM_WRITE64 MemWrite64;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiCpuIoPpiInServiceTableGuid;\r
+\r
+#endif\r
--- /dev/null
+/* @file\r
+ Provides decompression services to the PEI Foundatoin.\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: Decompress.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __DECOMPRESS_PPI_H__\r
+#define __DECOMPRESS_PPI_H__\r
+\r
+#define EFI_PEI_DECOMPRESS_PPI_GUID \\r
+ { 0x1a36e4e7, 0xfab6, 0x476a, { 0x8e, 0x75, 0x69, 0x5a, 0x5, 0x76, 0xfd, 0xd7 } }\r
+\r
+typedef struct _EFI_PEI_DECOMPRESS_PPI EFI_PEI_DECOMPRESS_PPI;;\r
+\r
+/** \r
+ Decompresses the data in a compressed section and returns it\r
+ as a series of standard PI Firmware File Sections. The\r
+ required memory is allocated from permanent memory.\r
+\r
+ @param This Points to this instance of the\r
+ EFI_PEI_DECOMPRESS_PEI PPI. InputSection Points to\r
+ the compressed section.\r
+\r
+ @param OutputBuffer Holds the returned pointer to the\r
+ decompressed sections.\r
+\r
+ @param OutputSize Holds the returned size of the decompress\r
+ section streams.\r
+\r
+ @retval EFI_SUCCESS The section was decompressed\r
+ successfully. OutputBuffer contains the\r
+ resulting data and OutputSize contains\r
+ the resulting size.\r
+\r
+ @retval EFI_OUT_OF_RESOURCES Unable to allocate sufficient\r
+ memory to hold the decompressed data.\r
+\r
+ @retval EFI_UNSUPPORTED The compression type specified\r
+ in the compression header is unsupported.\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_DECOMPRESS_DECOMPRESS)(\r
+ IN CONST EFI_PEI_DECOMPRESS_PPI *This,\r
+ IN CONST EFI_COMPRESSION_SECTION *InputSection,\r
+ OUT VOID **OutputBuffer,\r
+ OUT UINTN *OutputSize\r
+);\r
+\r
+\r
+/** \r
+ This PPI¡¯s single member function decompresses a compression\r
+ encapsulated section. It is used by the PEI Foundation to\r
+ process sectioned files. Prior to the installation of this PPI,\r
+ compression sections will be ignored.\r
+\r
+ @param Decompress Decompress a single compression section in\r
+ a firmware file.\r
+**/\r
+struct _EFI_PEI_DECOMPRESS_PPI {\r
+ EFI_PEI_DECOMPRESS_DECOMPRESS Decompress;\r
+};\r
+\r
+\r
+extern EFI_GUID gEfiPeiDecompressPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares DXE Initial Program Load PPI.\r
+ When the PEI core is done it calls the DXE IPL via this PPI.\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: DxeIpl.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+\r
+**/\r
+\r
+#ifndef __DXE_IPL_H__\r
+#define __DXE_IPL_H__\r
+\r
+#define EFI_DXE_IPL_PPI_GUID \\r
+ { \\r
+ 0xae8ce5d, 0xe448, 0x4437, {0xa8, 0xd7, 0xeb, 0xf5, 0xf1, 0x94, 0xf7, 0x31 } \\r
+ }\r
+\r
+typedef struct _EFI_DXE_IPL_PPI EFI_DXE_IPL_PPI;\r
+\r
+/**\r
+ The architectural PPI that the PEI Foundation invokes when \r
+ there are no additional PEIMs to invoke.\r
+\r
+ @param This Pointer to the DXE IPL PPI instance\r
+ @param PeiServices Pointer to the PEI Services Table.\r
+ @param HobList Pointer to the list of Hand-Off Block (HOB) entries.\r
+\r
+ @retval EFI_SUCCESS Upon this return code, the PEI Foundation should enter\r
+ some exception handling.Under normal circumstances, the DXE IPL PPI should not return.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_DXE_IPL_ENTRY) (\r
+ IN EFI_DXE_IPL_PPI *This,\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_HOB_POINTERS HobList\r
+ );\r
+\r
+/**\r
+ @par Ppi Description:\r
+ Final service to be invoked by the PEI Foundation.\r
+ The DXE IPL PPI is responsible for locating and loading the DXE Foundation.\r
+ The DXE IPL PPI may use PEI services to locate and load the DXE Foundation.\r
+\r
+ @param Entry\r
+ The entry point to the DXE IPL PPI.\r
+\r
+**/\r
+struct _EFI_DXE_IPL_PPI {\r
+ EFI_DXE_IPL_ENTRY Entry;\r
+};\r
+\r
+extern EFI_GUID gEfiDxeIplPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ PPI to be used to signal when the PEI ownership of the memory map\r
+ officially ends and DXE will take over\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: EndOfPeiPhase.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+\r
+**/\r
+\r
+#ifndef __END_OF_PEI_SIGNAL_PPI_H__\r
+#define __END_OF_PEI_SIGNAL_PPI_H__\r
+\r
+#define EFI_PEI_END_OF_PEI_PHASE_PPI_GUID \\r
+ { \\r
+ 0x605EA650, 0xC65C, 0x42e1, {0xBA, 0x80, 0x91, 0xA5, 0x2A, 0xB6, 0x18, 0xC6 } \\r
+ }\r
+\r
+extern EFI_GUID gEfiEndOfPeiSignalPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/* @file\r
+ This file provides functions for accessing a memory-mapped firmware volume of a specific format.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: FirmwareVolume.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00\r
+\r
+**/\r
+\r
+#ifndef __FIRMWARE_VOLUME_PPI_H__\r
+#define __FIRMWARE_VOLUME_PPI_H__\r
+\r
+//\r
+// The GUID for this PPI is the same as the firmware volume format GUID.\r
+// can be EFI_FIRMWARE_FILE_SYSTEM2_GUID or the GUID for a user-defined format. The\r
+// EFI_FIRMWARE_FILE_SYSTEM2_GUID is the PI Firmware Volume format.\r
+// \r
+\r
+typedef struct _EFI_PEI_FIRMWARE_VOLUME_PPI EFI_PEI_FIRMWARE_VOLUME_PPI;\r
+\r
+\r
+/**\r
+ Create a volume handle from the information in the buffer. For\r
+ memory-mapped firmware volumes, Buffer and BufferSize refer to\r
+ the start of the firmware volume and the firmware volume size.\r
+ For non memory-mapped firmware volumes, this points to a\r
+ buffer which contains the necessary information for creating\r
+ the firmware volume handle. Normally, these values are derived\r
+ from the EFI_FIRMWARE_VOLUME_INFO_PPI.\r
+ \r
+ \r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI\r
+ @param Buffer Points to the start of the buffer.\r
+ @param BufferSize Size of the buffer.\r
+ @param FvHandle Points to the returned firmware volume\r
+ handle. The firmware volume handle must\r
+ be unique within the system. \r
+\r
+\r
+ @retval EFI_SUCCESS Firmware volume handle.\r
+ @retval EFI_VOLUME_CORRUPTED Volume was corrupt.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_FV_PROCESS_FV) (\r
+ IN CONST EFI_PEI_FIRMWARE_VOLUME_PPI *This,\r
+ IN CONST VOID *Buffer,\r
+ IN CONST UINTN BufferSize,\r
+ OUT EFI_PEI_FV_HANDLE *FvHandle\r
+);\r
+\r
+\r
+/**\r
+ Create a volume handle from the information in the buffer. For\r
+ memory-mapped firmware volumes, Buffer and BufferSize refer to\r
+ the start of the firmware volume and the firmware volume size.\r
+ For non memory-mapped firmware volumes, this points to a\r
+ buffer which contains the necessary information for creating\r
+ the firmware volume handle. Normally, these values are derived\r
+ from the EFI_FIRMWARE_VOLUME_INFO_PPI.\r
+ \r
+ \r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI\r
+ @param Buffer Points to the start of the buffer.\r
+ @param BufferSize Size of the buffer.\r
+ @param FvHandle Points to the returned firmware volume\r
+ handle. The firmware volume handle must\r
+ be unique within the system. \r
+\r
+\r
+ @retval EFI_SUCCESS Firmware volume handle.\r
+ @retval EFI_VOLUME_CORRUPTED Volume was corrupt.\r
+\r
+**/\r
+\r
+/**\r
+ This service enables PEI modules to discover additional firmware files. The FileHandle must be\r
+ unique within the system.\r
+\r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI. SearchType A filter\r
+ to find only files of this type. Type\r
+ EFI_FV_FILETYPE_ALL causes no filtering to be\r
+ done.\r
+ @param FvHandle Handle of firmware volume in which to\r
+ search.\r
+\r
+ @param FileHandle Points to the current handle from which to\r
+ begin searching or NULL to start at the\r
+ beginning of the firmware volume. Updated\r
+ upon return to reflect the file found.\r
+\r
+\r
+ @retval EFI_SUCCESS The file was found.\r
+ @retval EFI_NOT_FOUND The file was not found. FileHandle\r
+ contains NULL.\r
+**/ \r
+typedef EFI_STATUS\r
+(EFIAPI *EFI_PEI_FV_FIND_FILE_TYPE) ( \r
+ IN CONST EFI_PEI_FIRMWARE_VOLUME_PPI *This, \r
+ IN CONST EFI_FV_FILETYPE SearchType, \r
+ IN CONST EFI_PEI_FV_HANDLE FvHandle,\r
+ IN OUT EFI_PEI_FILE_HANDLE *FileHandle \r
+);\r
+\r
+\r
+/**\r
+ \r
+ This service searches for files with a specific name, within\r
+ either the specified firmware volume or all firmware volumes.\r
+\r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI.\r
+\r
+ @param FileName A pointer to the name of the file to find\r
+ within the firmware volume.\r
+\r
+ @param FvHandle Upon entry, the pointer to the firmware\r
+ volume to search or NULL if all firmware\r
+ volumes should be searched. Upon exit, the\r
+ actual firmware volume in which the file was\r
+ found.\r
+\r
+ @param FileHandle Upon exit, points to the found file's\r
+ handle or NULL if it could not be found.\r
+\r
+ @retval EFI_SUCCESS File was found.\r
+\r
+ @param EFI_NOT_FOUND File was not found.\r
+\r
+ @param EFI_INVALID_PARAMETER FvHandle or FileHandle or\r
+ FileName was NULL.\r
+\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_FV_FIND_FILE_NAME) (\r
+ IN CONST EFI_PEI_FIRMWARE_VOLUME_PPI *This,\r
+ IN CONST EFI_GUID *FileName,\r
+ IN CONST EFI_PEI_FV_HANDLE FvHandle,\r
+ OUT EFI_PEI_FILE_HANDLE *FileHandle\r
+);\r
+\r
+\r
+/**\r
+ This function returns information about a specific\r
+ file, including its file name, type, attributes, starting\r
+ address and size. \r
+ \r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI.\r
+\r
+ @param FileHandle Handle of the file.\r
+\r
+ @param FileInfo Upon exit, points to the file????s\r
+ information.\r
+\r
+ @retval EFI_SUCCESS File information returned.\r
+ \r
+ @retval EFI_INVALID_PARAMETER If FileHandle does not\r
+ represent a valid file.\r
+ EFI_INVALID_PARAMETER If\r
+ FileInfo is NULL\r
+ \r
+**/ \r
+\r
+typedef\r
+EFI_STATUS (EFIAPI *EFI_PEI_FV_GET_FILE_INFO) (\r
+ IN CONST EFI_PEI_FIRMWARE_VOLUME_PPI *This, \r
+ IN CONST EFI_PEI_FILE_HANDLE FileHandle, \r
+ OUT EFI_FV_FILE_INFO *FileInfo\r
+);\r
+\r
+/**\r
+ This function returns information about the firmware\r
+ volume.\r
+ \r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI.\r
+ \r
+ @param FvHandle Handle to the firmware handle.\r
+ \r
+ @param VolumeInfo Points to the returned firmware volume\r
+ information.\r
+ \r
+ \r
+ @retval EFI_SUCCESS Information returned\r
+ successfully.\r
+ \r
+ @retval EFI_INVALID_PARAMETER FvHandle does not indicate a\r
+ valid firmware volume or VolumeInfo is NULL\r
+**/ \r
+typedef\r
+EFI_STATUS (EFIAPI *EFI_PEI_FV_GET_INFO)(\r
+ IN CONST EFI_PEI_FIRMWARE_VOLUME_PPI *This, \r
+ IN CONST EFI_PEI_FV_HANDLE FvHandle, \r
+ OUT EFI_FV_INFO *VolumeInfo\r
+);\r
+\r
+/**\r
+ This service enables PEI modules to discover sections of a given type within a valid file.\r
+ \r
+ @param This Points to this instance of the\r
+ EFI_PEI_FIRMWARE_VOLUME_PPI.\r
+ \r
+ @param SearchType A filter to find only sections of this\r
+ type.\r
+ \r
+ @param FileHandle Handle of firmware file in which to\r
+ search.\r
+ \r
+ @param SectionData Updated upon return to point to the\r
+ section found.\r
+ \r
+ @retval EFI_SUCCESS Section was found.\r
+ \r
+ @retval EFI_NOT_FOUND Section of the specified type was not\r
+ found. SectionData contains NULL.\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_FV_FIND_SECTION) (\r
+ IN CONST EFI_PEI_FIRMWARE_VOLUME_PPI *This,\r
+ IN CONST EFI_SECTION_TYPE SearchType,\r
+ IN CONST EFI_PEI_FILE_HANDLE FileHandle,\r
+ OUT VOID **SectionData\r
+);\r
+\r
+\r
+\r
+/*\r
+ This PPI provides functions for accessing a memory-mapped firmware volume of a specific format.\r
+\r
+ @param ProcessVolume Process a firmware volume and create a volume handle.\r
+ @param FindFileByType Find all files of a specific type.\r
+ @param FindFileByName Find the file with a specific name.\r
+ @param GetFileInfo Return the information about a specific file\r
+ @param GetVolumeInfo Return the firmware volume attributes.\r
+ @param FindSectionByType Find all sections of a specific type.\r
+\r
+**/\r
+struct _EFI_PEI_FIRMWARE_VOLUME_PPI {\r
+ EFI_PEI_FV_PROCESS_FV ProcessVolume;\r
+ EFI_PEI_FV_FIND_FILE_TYPE FindFileByType;\r
+ EFI_PEI_FV_FIND_FILE_NAME FindFileByName;\r
+ EFI_PEI_FV_GET_FILE_INFO GetFileInfo;\r
+ EFI_PEI_FV_GET_INFO GetVolumeInfo;\r
+ EFI_PEI_FV_FIND_SECTION FindSectionByType;\r
+} ;\r
+\r
+extern EFI_GUID gEfiPeiFirmwareVolumePpiGuid;\r
+\r
+#endif \r
--- /dev/null
+/* @file\r
+ This file provides location and format of a firmware volume.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: FirmwareVolumeInfo.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00\r
+\r
+**/\r
+\r
+#ifndef __EFI_PEI_FIRMWARE_VOLUME_INFO_H__\r
+#define __EFI_PEI_FIRMWARE_VOLUME_INFO_H__\r
+\r
+\r
+\r
+#define EFI_PEI_FIRMWARE_VOLUME_INFO_PPI_GUID \\r
+{ 0x49edb1c1, 0xbf21, 0x4761, { 0xbb, 0x12, 0xeb, 0x0, 0x31, 0xaa, 0xbb, 0x39 } }\r
+\r
+typedef struct _EFI_PEI_FIRMWARE_VOLUME_INFO_PPI EFI_PEI_FIRMWARE_VOLUME_INFO_PPI;\r
+\r
+/**\r
+ This PPI describes the location and format of a firmware volume. \r
+ The FvFormat can be EFI_FIRMWARE_FILE_SYSTEM2_GUID or the GUID for \r
+ a user-defined format. The EFI_FIRMWARE_FILE_SYSTEM2_GUID is \r
+ the PI Firmware Volume format.\r
+\r
+ @param FvFormat Unique identifier of the format of the memory-mapped firmware volume.\r
+\r
+ @param FvInfo Points to a buffer which allows the EFI_PEI_FIRMWARE_VOLUME_PPI to\r
+ process the volume. The format of this buffer is \r
+ specific to the FvFormat. For memory-mapped firmware volumes, \r
+ this typically points to the first byte of the firmware volume.\r
+\r
+ @param FvInfoSize Size of the data provided by FvInfo. For memory-mapped firmware volumes,\r
+ this is typically the size of the firmware volume.\r
+\r
+ @param ParentFvName If the firmware volume originally came from a firmware file, \r
+ then these point to the parent firmware volume\r
+ name and firmware volume file. If it did not originally come\r
+ from a firmware file, these should be NULL.\r
+\r
+ @param ParentFileName If the firmware volume originally came from a firmware file, \r
+ then these point to the parent firmware volume\r
+ name and firmware volume file. If it did not originally come\r
+ from a firmware file, these should be NULL.\r
+\r
+**/\r
+struct _EFI_PEI_FIRMWARE_VOLUME_INFO_PPI {\r
+ EFI_GUID FvFormat;\r
+ VOID *FvInfo;\r
+ UINT32 FvInfoSize;\r
+ EFI_GUID *ParentFvName;\r
+ EFI_GUID *ParentFileName;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiFirmwareVolumeInfoPpiGuid;\r
+\r
+#endif\r
+\r
--- /dev/null
+/* @file\r
+ If a GUID-defined section is encountered when doing section extraction, \r
+ the PEI Foundation or the EFI_PEI_FILE_LOADER_PPI instance \r
+ calls the appropriate instance of the GUIDed Section Extraction PPI \r
+ to extract the section stream contained therein.. \r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: GuidedSectionExtraction.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __EFI_GUIDED_SECTION_EXTRACTION_PPI_H__\r
+#define __EFI_GUIDED_SECTION_EXTRACTION_PPI_H__\r
+\r
+//\r
+// Typically, protocol interface structures are identified \r
+// by associating them with a GUID. Each instance of \r
+// a protocol with a given GUID must have \r
+// the same interface structure. While all instances of \r
+// the GUIDed Section Extraction PPI must have \r
+// the same interface structure, they do not all have \r
+// te same GUID. The GUID that is associated with \r
+// an instance of the GUIDed Section Extraction Protocol \r
+// is used to correlate it with the GUIDed section type \r
+// that it is intended to process.\r
+//\r
+\r
+\r
+typedef struct _EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI;\r
+\r
+//\r
+// Bit values for AuthenticationStatus\r
+//\r
+#define EFI_AUTH_STATUS_PLATFORM_OVERRIDE 0x01\r
+#define EFI_AUTH_STATUS_IMAGE_SIGNED 0x02\r
+#define EFI_AUTH_STATUS_NOT_TESTED 0x04\r
+#define EFI_AUTH_STATUS_TEST_FAILED 0x08\r
+\r
+/**\r
+ The ExtractSection() function processes the input section and\r
+ returns a pointer to the section contents. If the section being\r
+ extracted does not require processing (if the section\r
+ GuidedSectionHeader.Attributes has the\r
+ EFI_GUIDED_SECTION_PROCESSING_REQUIRED field cleared), then\r
+ OutputBuffer is just updated to point to the start of the\r
+ section's contents. Otherwise, *Buffer must be allocated\r
+ from PEI permanent memory.\r
+\r
+ @param This Indicates the\r
+ EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI instance.\r
+ Buffer containing the input GUIDed section to be\r
+ processed. OutputBuffer OutputBuffer is\r
+ allocated from PEI permanent memory and contains\r
+ the new section stream.\r
+ \r
+ @param OutputSize A pointer to a caller-allocated\r
+ UINTN in which the size of *OutputBuffer\r
+ allocation is stored. If the function\r
+ returns anything other than EFI_SUCCESS,\r
+ the value of OutputSize is undefined.\r
+ \r
+ @param AuthenticationStatus A pointer to a caller-allocated\r
+ UINT32 that indicates the\r
+ authentication status of the\r
+ output buffer. If the input\r
+ section's GuidedSectionHeader.\r
+ Attributes field has the\r
+ EFI_GUIDED_SECTION_AUTH_STATUS_VALID \r
+ bit as clear,\r
+ AuthenticationStatus must return\r
+ zero. These bits reflect the\r
+ status of the extraction\r
+ operation. If the function\r
+ returns anything other than\r
+ EFI_SUCCESS, the value of\r
+ AuthenticationStatus is\r
+ undefined.\r
+ \r
+ @retval EFI_SUCCESS The InputSection was\r
+ successfully processed and the\r
+ section contents were returned.\r
+ \r
+ @retval EFI_OUT_OF_RESOURCES The system has insufficient\r
+ resources to process the request.\r
+ \r
+ @reteval EFI_INVALID_PARAMETER The GUID in InputSection does\r
+ not match this instance of the\r
+ GUIDed Section Extraction PPI.\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_EXTRACT_GUIDED_SECTION)(\r
+ IN CONST EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI *This,\r
+ IN CONST VOID *InputSection,\r
+ OUT VOID **OutputBuffer,\r
+ OUT UINTN *OutputSize,\r
+ OUT UINT32 *AuthenticationStatus\r
+);\r
+\r
+\r
+\r
+/**\r
+ If a GUID-defined section is encountered when doing section extraction,\r
+ the PEI Foundation or the EFI_PEI_FILE_LOADER_PPI instance\r
+ calls the appropriate instance of the GUIDed Section\r
+ Extraction PPI to extract the section stream contained\r
+ therein.\r
+ \r
+ \r
+ @param ExtractSection Takes the GUIDed section as input and\r
+ produces the section stream data. See\r
+ the ExtractSection() function\r
+ description.\r
+ \r
+**/\r
+struct _EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI {\r
+ EFI_PEI_EXTRACT_GUIDED_SECTION ExtractSection;\r
+};\r
+\r
+\r
+\r
+#endif\r
+\r
--- /dev/null
+/** @file\r
+ Load image file from fv to memory. \r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: LoadFile.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __FV_FILE_LOADER_PPI_H__\r
+#define __FV_FILE_LOADER_PPI_H__\r
+\r
+#define EFI_PEI_LOAD_FILE_PPI_GUID \\r
+ { 0xb9e0abfe, 0x5979, 0x4914, { 0x97, 0x7f, 0x6d, 0xee, 0x78, 0xc2, 0x78, 0xa6 } }\r
+\r
+\r
+typedef struct _EFI_PEI_LOAD_FILE_PPI EFI_PEI_LOAD_FILE_PPI;\r
+\r
+/**\r
+ This service is the single member function of EFI_LOAD_FILE_PPI. This service separates\r
+ image loading and relocating from the PEI Foundation.\r
+ \r
+ @param This Interface pointer that implements\r
+ the Load File PPI instance.\r
+\r
+ @param FileHandle File handle of the file to load.\r
+ Type EFI_PEI_FILE_HANDLE is defined in\r
+ FfsFindNextFile().\r
+\r
+ @param ImageAddress Pointer to the address of the\r
+ loaded image.\r
+\r
+ @param ImageSize Pointer to the size of the loaded\r
+ image.\r
+\r
+ @param EntryPoint Pointer to the entry point of the\r
+ image.\r
+\r
+ @param AuthenticationState On exit, points to the attestation\r
+ authentication state of the image\r
+ or 0 if no attestation was\r
+ performed. The format of\r
+ AuthenticationState is defined in\r
+ EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI.ExtractSection()\r
+\r
+\r
+ @retval EFI_SUCCESS The image was loaded successfully.\r
+\r
+ @retval EFI_OUT_OF_RESOURCES There was not enough memory.\r
+\r
+ @retval EFI_LOAD_ERROR There was no supported image in\r
+ the file EFI_INVALID_PARAMETER\r
+ FileHandle was not a valid\r
+ firmware file handle.\r
+ @retval EFI_INVALID_PARAMETER EntryPoint was NULL.\r
+\r
+ @retval EFI_NOT_SUPPORTED An image requires relocations or\r
+ is not memory mapped.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_LOAD_FILE) (\r
+ IN CONST EFI_PEI_LOAD_FILE_PPI *This,\r
+ IN CONST EFI_PEI_FILE_HANDLE FileHandle,\r
+ OUT EFI_PHYSICAL_ADDRESS *ImageAddress,\r
+ OUT UINT64 *ImageSize,\r
+ OUT EFI_PHYSICAL_ADDRESS *EntryPoint,\r
+ OUT UINT32 *AuthenticationState\r
+);\r
+\r
+\r
+/**\r
+ This PPI is a pointer to the Load File service.\r
+ This service will be published by a PEIM. The PEI Foundation\r
+ will use this service to launch the known PEI module images.\r
+ \r
+ \r
+ @param LoadFile Loads a PEIM into memory for subsequent\r
+ execution. See the LoadFile() function\r
+ description.\r
+ \r
+**/\r
+struct _EFI_PEI_LOAD_FILE_PPI {\r
+ EFI_PEI_LOAD_FILE LoadFile;\r
+};\r
+\r
+\r
+\r
+#define EFI_PEI_FV_FILE_LOADER_GUID \\r
+ { \\r
+ 0x7e1f0d85, 0x4ff, 0x4bb2, {0x86, 0x6a, 0x31, 0xa2, 0x99, 0x6a, 0x48, 0xa8 } \\r
+ }\r
+\r
+typedef struct _EFI_PEI_FV_FILE_LOADER_PPI EFI_PEI_FV_FILE_LOADER_PPI;\r
+\r
+/**\r
+ Loads a PEIM into memory for subsequent execution.\r
+\r
+ @param This Interface pointer that implements the Load File PPI instance.\r
+ @param FfsHeader Pointer to the FFS header of the file to load.\r
+ @param ImageAddress Pointer to the address of the loaded Image\r
+ @param ImageSize Pointer to the size of the loaded image.\r
+ @param EntryPoint Pointer to the entry point of the image.\r
+\r
+ @retval EFI_SUCCESS The image was loaded successfully.\r
+ @retval EFI_OUT_OF_RESOURCES There was not enough memory.\r
+ @retval EFI_INVALID_PARAMETER The contents of the FFS file did not\r
+ contain a valid PE/COFF image that could be loaded.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_FV_LOAD_FILE) (\r
+ IN EFI_PEI_FV_FILE_LOADER_PPI *This,\r
+ IN EFI_FFS_FILE_HEADER *FfsHeader,\r
+ OUT EFI_PHYSICAL_ADDRESS *ImageAddress,\r
+ OUT UINT64 *ImageSize,\r
+ OUT EFI_PHYSICAL_ADDRESS *EntryPoint\r
+ );\r
+\r
+/**\r
+ @par Ppi Description:\r
+ This PPI is a pointer to the Load File service. This service will be \r
+ published by a PEIM.The PEI Foundation will use this service to \r
+ launch the known non-XIP PE/COFF PEIM images. This service may \r
+ depend upon the presence of the EFI_PEI_PERMANENT_MEMORY_INSTALLED_PPI.\r
+\r
+ @param FvLoadFile\r
+ Loads a PEIM into memory for subsequent execution\r
+\r
+**/\r
+struct _EFI_PEI_FV_FILE_LOADER_PPI {\r
+ EFI_PEI_FV_LOAD_FILE FvLoadFile;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiFvFileLoaderPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/* @file\r
+ The file descript the PPI which notifies other drivers \r
+ of the PEIM being initialized by the PEI Dispatcher.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: LoadImage.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __LOADED_IMAGE_PPI_H__\r
+#define __LOADED_IMAGE_PPI_H__\r
+\r
+#define EFI_PEI_LOADED_IMAGE_PPI_GUID \\r
+ { 0xc1fcd448, 0x6300, 0x4458, { 0xb8, 0x64, 0x28, 0xdf, 0x1, 0x53, 0x64, 0xbc } }\r
+\r
+\r
+typedef struct _EFI_PEI_LOADED_IMAGE_PPI EFI_PEI_LOADED_IMAGE_PPI;\r
+\r
+/*\r
+ This interface is installed by the PEI Dispatcher after the image has been\r
+ loaded and after all security checks have been performed, \r
+ to notify other PEIMs of the files which are being loaded.\r
+\r
+ @param ImageAddress Address of the image at the address where it will be executed.\r
+\r
+ @param ImageSize Size of the image as it will be executed.\r
+\r
+ @param FileHandle File handle from which the image was loaded. Can be NULL, \r
+ indicating the image was not loaded from a handle.\r
+\r
+**/\r
+struct _EFI_PEI_LOADED_IMAGE_PPI {\r
+ EFI_PHYSICAL_ADDRESS ImageAddress;\r
+ UINT64 ImageSize;\r
+ EFI_PEI_FILE_HANDLE FileHandle;\r
+};\r
+\r
+\r
+extern EFI_GUID gEfiPeiLoadedImagePpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Boot Mode PPI\r
+ The Master Boot Mode PPI is installed by a PEIM to signal that a final \r
+ boot has been determined and set. This signal is useful in that PEIMs \r
+ with boot-mode-specific behavior can put this PPI in their dependency expression.\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: MasterBootMode.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+\r
+**/\r
+\r
+#ifndef __MASTER_BOOT_MODE_PPI_H__\r
+#define __MASTER_BOOT_MODE_PPI_H__\r
+\r
+#define EFI_PEI_MASTER_BOOT_MODE_PEIM_PPI \\r
+ { \\r
+ 0x7408d748, 0xfc8c, 0x4ee6, {0x92, 0x88, 0xc4, 0xbe, 0xc0, 0x92, 0xa4, 0x10 } \\r
+ }\r
+\r
+extern EFI_GUID gEfiPeiMasterBootModePpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Memory Discovered PPI.\r
+ This PPI is installed by the PEI Foundation at the point of system \r
+ evolution when the permanent memory size has been registered and \r
+ waiting PEIMs can use the main memory store. \r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: MemoryDiscovered.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PEI CIS\r
+ Version 0.91.\r
+\r
+**/\r
+\r
+#ifndef __PEI_MEMORY_DISCOVERED_PPI_H__\r
+#define __PEI_MEMORY_DISCOVERED_PPI_H__\r
+\r
+#define EFI_PEI_PERMANENT_MEMORY_INSTALLED_PPI_GUID \\r
+ { \\r
+ 0xf894643d, 0xc449, 0x42d1, {0x8e, 0xa8, 0x85, 0xbd, 0xd8, 0xc6, 0x5b, 0xde } \\r
+ }\r
+\r
+extern EFI_GUID gEfiPeiMemoryDiscoveredPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/* @file\r
+ Platform Configuration Database (PCD) PPI\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: Pcd.h\r
+\r
+**/\r
+\r
+#ifndef __PCD_PPI_H__\r
+#define __PCD_PPI_H__\r
+\r
+\r
+#define PCD_PPI_GUID \\r
+ { 0x6e81c58, 0x4ad7, 0x44bc, { 0x83, 0x90, 0xf1, 0x2, 0x65, 0xf7, 0x24, 0x80 } }\r
+\r
+#define PCD_INVALID_TOKEN_NUMBER ((UINTN) 0)\r
+\r
+\r
+\r
+/**\r
+ Sets the SKU value for subsequent calls to set or get PCD token values.\r
+\r
+ SetSku() sets the SKU Id to be used for subsequent calls to set or get PCD values. \r
+ SetSku() is normally called only once by the system.\r
+\r
+ For each item (token), the database can hold a single value that applies to all SKUs, \r
+ or multiple values, where each value is associated with a specific SKU Id. Items with multiple, \r
+ SKU-specific values are called SKU enabled. \r
+ \r
+ The SKU Id of zero is reserved as a default. The valid SkuId range is 1 to 255. \r
+ For tokens that are not SKU enabled, the system ignores any set SKU Id and works with the \r
+ single value for that token. For SKU-enabled tokens, the system will use the SKU Id set by the \r
+ last call to SetSku(). If no SKU Id is set or the currently set SKU Id isn't valid for the specified token, \r
+ the system uses the default SKU Id. If the system attempts to use the default SKU Id and no value has been \r
+ set for that Id, the results are unpredictable.\r
+\r
+ @param[in] SkuId The SKU value that will be used when the PCD service will retrieve and \r
+ set values associated with a PCD token.\r
+\r
+ @retval VOID\r
+\r
+**/\r
+typedef \r
+VOID\r
+(EFIAPI *PCD_PPI_SET_SKU) (\r
+ IN UINTN SkuId\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 8-bit value for a given PCD token.\r
+\r
+ Retrieves the current byte-sized value for a PCD token number. \r
+ If the TokenNumber is invalid, the results are unpredictable.\r
+ \r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The UINT8 value.\r
+ \r
+**/\r
+typedef\r
+UINT8\r
+(EFIAPI *PCD_PPI_GET8) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 16-bit value for a given PCD token.\r
+\r
+ Retrieves the current 16-bits value for a PCD token number. \r
+ If the TokenNumber is invalid, the results are unpredictable.\r
+ \r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The UINT16 value.\r
+ \r
+**/\r
+typedef\r
+UINT16\r
+(EFIAPI *PCD_PPI_GET16) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 32-bit value for a given PCD token.\r
+\r
+ Retrieves the current 32-bits value for a PCD token number. \r
+ If the TokenNumber is invalid, the results are unpredictable.\r
+ \r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The UINT32 value.\r
+ \r
+**/\r
+typedef\r
+UINT32\r
+(EFIAPI *PCD_PPI_GET32) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 64-bit value for a given PCD token.\r
+\r
+ Retrieves the current 64-bits value for a PCD token number. \r
+ If the TokenNumber is invalid, the results are unpredictable.\r
+ \r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The UINT64 value.\r
+ \r
+**/\r
+typedef\r
+UINT64\r
+(EFIAPI *PCD_PPI_GET64) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves a pointer to a value for a given PCD token.\r
+\r
+ Retrieves the current pointer to the buffer for a PCD token number. \r
+ Do not make any assumptions about the alignment of the pointer that \r
+ is returned by this function call. If the TokenNumber is invalid, \r
+ the results are unpredictable.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The pointer to the buffer to be retrived.\r
+ \r
+**/\r
+typedef\r
+VOID *\r
+(EFIAPI *PCD_PPI_GET_POINTER) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves a Boolean value for a given PCD token.\r
+\r
+ Retrieves the current boolean value for a PCD token number. \r
+ Do not make any assumptions about the alignment of the pointer that \r
+ is returned by this function call. If the TokenNumber is invalid, \r
+ the results are unpredictable.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The Boolean value.\r
+ \r
+**/\r
+typedef\r
+BOOLEAN\r
+(EFIAPI *PCD_PPI_GET_BOOLEAN) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves the size of the value for a given PCD token.\r
+\r
+ Retrieves the current size of a particular PCD token. \r
+ If the TokenNumber is invalid, the results are unpredictable.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size of the value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+UINTN\r
+(EFIAPI *PCD_PPI_GET_SIZE) (\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 8-bit value for a given PCD token.\r
+\r
+ Retrieves the 8-bit value of a particular PCD token. \r
+ If the TokenNumber is invalid or the token space\r
+ specified by Guid does not exist, the results are \r
+ unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size 8-bit value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+UINT8\r
+(EFIAPI *PCD_PPI_GET_EX_8) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 16-bit value for a given PCD token.\r
+\r
+ Retrieves the 16-bit value of a particular PCD token. \r
+ If the TokenNumber is invalid or the token space\r
+ specified by Guid does not exist, the results are \r
+ unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size 16-bit value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+UINT16\r
+(EFIAPI *PCD_PPI_GET_EX_16) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 32-bit value for a given PCD token.\r
+\r
+ Retrieves the 32-bit value of a particular PCD token. \r
+ If the TokenNumber is invalid or the token space\r
+ specified by Guid does not exist, the results are \r
+ unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size 32-bit value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+UINT32\r
+(EFIAPI *PCD_PPI_GET_EX_32) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an 64-bit value for a given PCD token.\r
+\r
+ Retrieves the 64-bit value of a particular PCD token. \r
+ If the TokenNumber is invalid or the token space\r
+ specified by Guid does not exist, the results are \r
+ unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size 64-bit value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+UINT64\r
+(EFIAPI *PCD_PPI_GET_EX_64) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves a pointer to a value for a given PCD token.\r
+\r
+ Retrieves the current pointer to the buffer for a PCD token number. \r
+ Do not make any assumptions about the alignment of the pointer that \r
+ is returned by this function call. If the TokenNumber is invalid, \r
+ the results are unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The pointer to the buffer to be retrived.\r
+ \r
+**/\r
+typedef\r
+VOID *\r
+(EFIAPI *PCD_PPI_GET_EX_POINTER) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves an Boolean value for a given PCD token.\r
+\r
+ Retrieves the Boolean value of a particular PCD token. \r
+ If the TokenNumber is invalid or the token space\r
+ specified by Guid does not exist, the results are \r
+ unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size Boolean value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+BOOLEAN\r
+(EFIAPI *PCD_PPI_GET_EX_BOOLEAN) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves the size of the value for a given PCD token.\r
+\r
+ Retrieves the current size of a particular PCD token. \r
+ If the TokenNumber is invalid, the results are unpredictable.\r
+\r
+ @param[in] Guid The token space for the token number.\r
+ @param[in] TokenNumber The PCD token number. \r
+\r
+ @return The size of the value for the PCD token.\r
+ \r
+**/\r
+typedef\r
+UINTN\r
+(EFIAPI *PCD_PPI_GET_EX_SIZE) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 8-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET8) (\r
+ IN UINTN TokenNumber,\r
+ IN UINT8 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 16-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET16) (\r
+ IN UINTN TokenNumber,\r
+ IN UINT16 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 32-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET32) (\r
+ IN UINTN TokenNumber,\r
+ IN UINT32 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 64-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET64) (\r
+ IN UINTN TokenNumber,\r
+ IN UINT64 Value\r
+ );\r
+\r
+\r
+\r
+\r
+/**\r
+ Sets a value of a specified size for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in, out] SizeOfBuffer A pointer to the length of the value being set for the PCD token. \r
+ On input, if the SizeOfValue is greater than the maximum size supported \r
+ for this TokenNumber then the output value of SizeOfValue will reflect \r
+ the maximum size supported for this TokenNumber.\r
+ @param[in] Buffer The buffer to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_POINTER) (\r
+ IN UINTN TokenNumber,\r
+ IN OUT UINTN *SizeOfBuffer,\r
+ IN VOID *Buffer\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an Boolean value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_BOOLEAN) (\r
+ IN UINTN TokenNumber,\r
+ IN BOOLEAN Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 8-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_EX_8) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber,\r
+ IN UINT8 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 16-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_EX_16) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber,\r
+ IN UINT16 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 32-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_EX_32) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber,\r
+ IN UINT32 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an 64-bit value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_EX_64) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber,\r
+ IN UINT64 Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets a value of a specified size for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in, out] SizeOfBuffer A pointer to the length of the value being set for the PCD token. \r
+ On input, if the SizeOfValue is greater than the maximum size supported \r
+ for this TokenNumber then the output value of SizeOfValue will reflect \r
+ the maximum size supported for this TokenNumber.\r
+ @param[in] Buffer The buffer to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_EX_POINTER) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber,\r
+ IN OUT UINTN *SizeOfBuffer,\r
+ IN VOID *Buffer\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Sets an Boolean value for a given PCD token.\r
+\r
+ When the PCD service sets a value, it will check to ensure that the \r
+ size of the value being set is compatible with the Token's existing definition. \r
+ If it is not, an error will be returned.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Value The value to set for the PCD token.\r
+\r
+ @retval EFI_SUCCESS Procedure returned successfully.\r
+ @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data \r
+ being set was incompatible with a call to this function. \r
+ Use GetSize() to retrieve the size of the target data.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the requested token number.\r
+ \r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_SET_EX_BOOLEAN) (\r
+ IN CONST EFI_GUID *Guid,\r
+ IN UINTN TokenNumber,\r
+ IN BOOLEAN Value\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Callback on SET function prototype definition.\r
+\r
+ This notification function serves two purposes. Firstly, it notifies the module \r
+ which did the registration that the value of this PCD token has been set. Secondly, \r
+ it provides a mechanism for the module which did the registration to intercept the set \r
+ operation and override the value been set if necessary. After the invocation of the \r
+ callback function, TokenData will be used by PCD service PEIM to modify the internal data \r
+ in PCD database.\r
+\r
+ @param[in] CallBackGuid The PCD token GUID being set.\r
+ @param[in] CallBackToken The PCD token number being set.\r
+ @param[in, out] TokenData A pointer to the token data being set.\r
+ @param[in] TokenDataSize The size, in bytes, of the data being set.\r
+\r
+ @retval VOID\r
+\r
+**/\r
+typedef\r
+VOID\r
+(EFIAPI *PCD_PPI_CALLBACK) (\r
+ IN CONST EFI_GUID *CallBackGuid, OPTIONAL\r
+ IN UINTN CallBackToken,\r
+ IN OUT VOID *TokenData,\r
+ IN UINTN TokenDataSize\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Specifies a function to be called anytime the value of a designated token is changed.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] CallBackFunction The function prototype called when the value associated with the CallBackToken is set. \r
+\r
+ @retval EFI_SUCCESS The PCD service has successfully established a call event \r
+ for the CallBackToken requested.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the referenced token number.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_CALLBACK_ONSET) (\r
+ IN CONST EFI_GUID *Guid, OPTIONAL\r
+ IN UINTN TokenNumber,\r
+ IN PCD_PPI_CALLBACK CallBackFunction\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Cancels a previously set callback function for a particular PCD token number.\r
+\r
+ @param[in] TokenNumber The PCD token number. \r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in] CallBackFunction The function prototype called when the value associated with the CallBackToken is set. \r
+\r
+ @retval EFI_SUCCESS The PCD service has successfully established a call event \r
+ for the CallBackToken requested.\r
+ @retval EFI_NOT_FOUND The PCD service could not find the referenced token number.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_CANCEL_CALLBACK) (\r
+ IN CONST EFI_GUID *Guid, OPTIONAL\r
+ IN UINTN TokenNumber,\r
+ IN PCD_PPI_CALLBACK CallBackFunction\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves the next valid PCD token for a given namespace.\r
+\r
+ @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.\r
+ @param[in, out] TokenNumber A pointer to the PCD token number to use to find the subsequent token number.\r
+ If the input token namespace or token number does not exist on the platform, an error is \r
+ returned and the value of *TokenNumber is undefined. To retrieve the "first" token, \r
+ have the pointer reference a TokenNumber value of 0. If the input token number is 0 \r
+ and there is no valid token number for this token namespace, *TokenNumber will be \r
+ assigned to 0 and the function return EFI_SUCCESS. If the token number is the last valid \r
+ token number, *TokenNumber will be assigned to 0 and the function return EFI_SUCCESS.\r
+\r
+ @retval EFI_SUCCESS The PCD service has retrieved the next valid token number. \r
+ Or the input token number is already the last valid token number in the PCD database. \r
+ In the later case, *TokenNumber is updated with the value of 0.\r
+ @retval EFI_NOT_FOUND If this input token number and token namespace does not exist on the platform.\r
+\r
+**/\r
+typedef \r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_GET_NEXT_TOKEN) (\r
+ IN CONST EFI_GUID *Guid, OPTIONAL\r
+ IN OUT UINTN *TokenNumber\r
+ );\r
+\r
+\r
+\r
+/**\r
+ Retrieves the next valid PCD token namespace for a given namespace.\r
+\r
+ @param[in, out] Guid An indirect pointer to EFI_GUID. On input it designates a known \r
+ token namespace from which the search will start. On output, it designates \r
+ the next valid token namespace on the platform. If the input token namespace \r
+ does not exist on the platform, an error is returned and the value of *Guid is \r
+ undefined. If *Guid is NULL, then the GUID of the first token space of the \r
+ current platform is assigned to *Guid the function return EFI_SUCCESS. \r
+ If *Guid is NULL and there is no namespace exist in the platform other than the default \r
+ (NULL) tokennamespace, *Guid is unchanged and the function return EFI_SUCCESS. \r
+ If this input token namespace is the last namespace on the platform, \r
+ *Guid will be assigned to NULL and the function return EFI_SUCCESS.\r
+\r
+ @retval EFI_SUCCESS The PCD service has retrieved the next valid token namespace. \r
+ Or the input token namespace is already the last valid token \r
+ number in the PCD database. In the later case, *Guid is updated \r
+ with the value of NULL. Or the input token name space is NULL and there \r
+ is no valid token namespace other than the default namespace (NULL).\r
+ @retval EFI_NOT_FOUND If the input token namespace does not exist on the platform.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *PCD_PPI_GET_NEXT_TOKENSPACE) (\r
+ IN OUT CONST EFI_GUID **Guid\r
+ );\r
+\r
+\r
+\r
+//\r
+// Interface structure for the PCD PPI\r
+//\r
+typedef struct {\r
+ PCD_PPI_SET_SKU SetSku;\r
+\r
+ PCD_PPI_GET8 Get8;\r
+ PCD_PPI_GET16 Get16;\r
+ PCD_PPI_GET32 Get32;\r
+ PCD_PPI_GET64 Get64;\r
+ PCD_PPI_GET_POINTER GetPtr;\r
+ PCD_PPI_GET_BOOLEAN GetBool;\r
+ PCD_PPI_GET_SIZE GetSize;\r
+\r
+ PCD_PPI_GET_EX_8 Get8Ex;\r
+ PCD_PPI_GET_EX_16 Get16Ex;\r
+ PCD_PPI_GET_EX_32 Get32Ex;\r
+ PCD_PPI_GET_EX_64 Get64Ex;\r
+ PCD_PPI_GET_EX_POINTER GetPtrEx;\r
+ PCD_PPI_GET_EX_BOOLEAN GetBoolEx;\r
+ PCD_PPI_GET_EX_SIZE GetSizeEx;\r
+\r
+ PCD_PPI_SET8 Set8;\r
+ PCD_PPI_SET16 Set16;\r
+ PCD_PPI_SET32 Set32;\r
+ PCD_PPI_SET64 Set64;\r
+ PCD_PPI_SET_POINTER SetPtr;\r
+ PCD_PPI_SET_BOOLEAN SetBool;\r
+\r
+ PCD_PPI_SET_EX_8 Set8Ex;\r
+ PCD_PPI_SET_EX_16 Set16Ex;\r
+ PCD_PPI_SET_EX_32 Set32Ex;\r
+ PCD_PPI_SET_EX_64 Set64Ex;\r
+ PCD_PPI_SET_EX_POINTER SetPtrEx;\r
+ PCD_PPI_SET_EX_BOOLEAN SetBoolEx;\r
+\r
+ PCD_PPI_CALLBACK_ONSET CallbackOnSet;\r
+ PCD_PPI_CANCEL_CALLBACK CancelCallback;\r
+ PCD_PPI_GET_NEXT_TOKEN GetNextToken;\r
+ PCD_PPI_GET_NEXT_TOKENSPACE GetNextTokenSpace;\r
+} PCD_PPI;\r
+\r
+\r
+extern EFI_GUID gPcdPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares PciCfg PPI used to access PCI configuration space in PEI\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: PciCfg.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __PEI_PCI_CFG2_H__\r
+#define __PEI_PCI_CFG2_H__\r
+\r
+\r
+#define EFI_PEI_PCI_CFG2_PPI_GUID \\r
+ { 0x57a449a, 0x1fdc, 0x4c06, { 0xbf, 0xc9, 0xf5, 0x3f, 0x6a, 0x99, 0xbb, 0x92 } }\r
+\r
+\r
+typedef struct _EFI_PEI_PCI_CFG2_PPI EFI_PEI_PCI_CFG2_PPI;\r
+\r
+#define EFI_PEI_PCI_CFG_ADDRESS(bus,dev,func,reg) \\r
+ (((bus) << 24) | \\r
+ ((dev) << 16) | \\r
+ ((func) << 8) | \\r
+ ((reg) < 256 ? (reg) : ((UINT64) (reg) << 32)));\r
+\r
+//\r
+// EFI_PEI_PCI_CFG_PPI_WIDTH\r
+//\r
+typedef enum {\r
+ EfiPeiPciCfgWidthUint8 = 0,\r
+ EfiPeiPciCfgWidthUint16 = 1,\r
+ EfiPeiPciCfgWidthUint32 = 2,\r
+ EfiPeiPciCfgWidthUint64 = 3,\r
+ EfiPeiPciCfgWidthMaximum\r
+} EFI_PEI_PCI_CFG_PPI_WIDTH;\r
+\r
+//\r
+// EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS\r
+//\r
+typedef struct {\r
+ UINT8 Register;\r
+ UINT8 Function;\r
+ UINT8 Device;\r
+ UINT8 Bus;\r
+ UINT32 ExtendedRegister;\r
+} EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS;\r
+\r
+/**\r
+ Reads from or write to a given location in the PCI configuration space.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table published by the PEI Foundation.\r
+\r
+ @param This Pointer to local data for the interface.\r
+\r
+ @param Width The width of the access. Enumerated in bytes. \r
+ See EFI_PEI_PCI_CFG_PPI_WIDTH above.\r
+\r
+ @param Address The physical address of the access. The format of \r
+ the address is described by EFI_PEI_PCI_CFG_PPI_PCI_ADDRESS.\r
+\r
+ @param Buffer A pointer to the buffer of data..\r
+\r
+\r
+ @retval EFI_SUCCESS The function completed successfully.\r
+\r
+ @retval EFI_DEVICE_ERROR There was a problem with the transaction.\r
+\r
+ @retval EFI_DEVICE_NOT_READY The device is not capable of supporting the operation at this\r
+ time.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_PCI_CFG_PPI_IO) (\r
+ IN CONST EFI_PEI_SERVICES **PeiServices,\r
+ IN CONST EFI_PEI_PCI_CFG2_PPI *This,\r
+ IN CONST EFI_PEI_PCI_CFG_PPI_WIDTH Width,\r
+ IN CONST UINT64 Address,\r
+ IN OUT VOID *Buffer\r
+);\r
+\r
+\r
+/**\r
+ PCI read-modify-write operation.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table \r
+ published by the PEI Foundation.\r
+\r
+ @param This Pointer to local data for the interface.\r
+\r
+ @param Width The width of the access. Enumerated in bytes. Type\r
+ EFI_PEI_PCI_CFG_PPI_WIDTH is defined in Read().\r
+\r
+ @param Address The physical address of the access.\r
+\r
+ @param SetBits Points to value to bitwise-OR with the read configuration value. \r
+\r
+ The size of the value is determined by Width.\r
+\r
+ @param ClearBits Points to the value to negate and bitwise-AND with the read configuration value. \r
+ The size of the value is determined by Width.\r
+\r
+\r
+ @retval EFI_SUCCESS The function completed successfully.\r
+\r
+ @retval EFI_DEVICE_ERROR There was a problem with the transaction.\r
+\r
+ @retval EFI_DEVICE_NOT_READY The device is not capable of supporting \r
+ the operation at this time.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_PCI_CFG_PPI_RW) (\r
+ IN CONST EFI_PEI_SERVICES **PeiServices,\r
+ IN CONST EFI_PEI_PCI_CFG2_PPI *This,\r
+ IN CONST EFI_PEI_PCI_CFG_PPI_WIDTH Width,\r
+ IN CONST UINT64 Address,\r
+ IN CONST VOID *SetBits,\r
+ IN CONST VOID *ClearBits\r
+);\r
+\r
+/**\r
+ @par Ppi Description:\r
+ The EFI_PEI_PCI_CFG_PPI interfaces are used to abstract accesses to PCI \r
+ controllers behind a PCI root bridge controller.\r
+\r
+ @param Read PCI read services. See the Read() function description.\r
+\r
+ @param Write PCI write services. See the Write() function description.\r
+\r
+ @param Modify PCI read-modify-write services. See the Modify() function description.\r
+\r
+ @param Segment The PCI bus segment which the specified functions will access.\r
+\r
+**/\r
+struct _EFI_PEI_PCI_CFG2_PPI {\r
+ EFI_PEI_PCI_CFG_PPI_IO Read;\r
+ EFI_PEI_PCI_CFG_PPI_IO Write;\r
+ EFI_PEI_PCI_CFG_PPI_RW Modify;\r
+ UINT16 Segment;\r
+};\r
+\r
+\r
+extern EFI_GUID gEfiPciCfg2PpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Read-only Variable Service PPI\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: ReadOnlyVariable.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __PEI_READ_ONLY_VARIABLE2_PPI_H__\r
+#define __PEI_READ_ONLY_VARIABLE2_PPI_H__\r
+\r
+#define EFI_PEI_READ_ONLY_VARIABLE2_PPI_GUID \\r
+ { 0x2ab86ef5, 0xecb5, 0x4134, { 0xb5, 0x56, 0x38, 0x54, 0xca, 0x1f, 0xe1, 0xb4 } }\r
+\r
+\r
+typedef struct _EFI_PEI_READ_ONLY_VARIABLE2_PPI EFI_PEI_READ_ONLY_VARIABLE2_PPI;\r
+\r
+/**\r
+ Read the specified variable from the UEFI variable store. If the Data \r
+ buffer is too small to hold the contents of the variable, \r
+ the error EFI_BUFFER_TOO_SMALL is returned and DataSize is set to the\r
+ required buffer size to obtain the data.\r
+\r
+ @param This A pointer to this instance of the EFI_PEI_READ_ONLY_VARIABLE2_PPI.\r
+\r
+ @param VariableName A pointer to a null-terminated string that is the variable¡¯s name.\r
+\r
+ @param VendorGuid A pointer to an EFI_GUID that is the variable¡¯s GUID. The combination of\r
+ VariableGuid and VariableName must be unique.\r
+\r
+ @param Attributes If non-NULL, on return, points to the variable¡¯s attributes. See ¡°Related Definitons¡±\r
+ below for possible attribute values.\r
+\r
+ @param DataSize On entry, points to the size in bytes of the Data buffer. On return, points to the size of\r
+ the data returned in Data.\r
+\r
+ @param Data Points to the buffer which will hold the returned variable value.\r
+\r
+\r
+ @retval EFI_SUCCESS The function completed successfully.\r
+\r
+ @retval EFI_NOT_FOUND The variable was not found.\r
+\r
+ @retval EFI_BUFFER_TOO_SMALL The DataSize is too small for the resulting data. \r
+ DataSize is updated with the size required for \r
+ the specified variable.\r
+\r
+ @retval EFI_INVALID_PARAMETER VariableName, VariableGuid, DataSize or Data is NULL.\r
+\r
+ @retval EFI_DEVICE_ERROR The variable could not be retrieved because of a device error.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_GET_VARIABLE2)(\r
+ IN CONST EFI_PEI_READ_ONLY_VARIABLE2_PPI *This,\r
+ IN CONST CHAR16 *VariableName,\r
+ IN CONST EFI_GUID *VariableGuid,\r
+ OUT UINT32 *Attributes,\r
+ IN OUT UINTN *DataSize,\r
+ OUT VOID *Data\r
+);\r
+\r
+\r
+/**\r
+ This function is called multiple times to retrieve the VariableName \r
+ and VariableGuid of all variables currently available in the system. \r
+ On each call, the previous results are passed into the interface, \r
+ and, on return, the interface returns the data for the next \r
+ interface. When the entire variable list has been returned, \r
+ EFI_NOT_FOUND is returned.\r
+\r
+ @param This A pointer to this instance of the EFI_PEI_READ_ONLY_VARIABLE2_PPI.\r
+\r
+ @param VariableNameSize On entry, points to the size of the buffer pointed to by VariableName.\r
+\r
+ @param VariableName On entry, a pointer to a null-terminated string that is the variable¡¯s name.\r
+ On return, points to the next variable¡¯s null-terminated name string.\r
+\r
+ @param VendorGuid On entry, a pointer to an UEFI _GUID that is the variable¡¯s GUID. \r
+ On return, a pointer to the next variable¡¯s GUID.\r
+\r
+\r
+ @retval EFI_SUCCESS The variable was read successfully.\r
+\r
+ @retval EFI_NOT_FOUND The variable could not be found.\r
+\r
+ @retval EFI_BUFFER_TOO_SMALL The VariableNameSize is too small for the resulting\r
+ data. VariableNameSize is updated with the size\r
+ required for the specified variable.\r
+\r
+ @retval EFI_INVALID_PARAMETER VariableName, VariableGuid or\r
+ VariableNameSize is NULL.\r
+\r
+ @retval EFI_DEVICE_ERROR The variable could not be retrieved because of a device error.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_NEXT_VARIABLE_NAME2) (\r
+ IN CONST EFI_PEI_READ_ONLY_VARIABLE2_PPI *This,\r
+ IN OUT UINTN *VariableNameSize,\r
+ IN OUT CHAR16 *VariableName,\r
+ IN OUT EFI_GUID *VariableGuid\r
+);\r
+\r
+/**\r
+ This PPI provides a lightweight, read-only variant of the full EFI \r
+ variable services. \r
+\r
+ @param GetVariable\r
+ A service to ascertain a given variable name.\r
+\r
+ @param GetNextVariableName\r
+ A service to ascertain a variable based upon a given, known variable\r
+\r
+**/\r
+struct _EFI_PEI_READ_ONLY_VARIABLE2_PPI {\r
+ EFI_PEI_GET_VARIABLE2 GetVariable;\r
+ EFI_PEI_NEXT_VARIABLE_NAME2 NextVariableName;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiReadOnlyVariable2PpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Reset PPI used to reset the platform\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: Reset.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+\r
+**/\r
+\r
+#ifndef __RESET_PPI_H__\r
+#define __RESET_PPI_H__\r
+\r
+#define EFI_PEI_RESET_PPI_GUID \\r
+ { \\r
+ 0xef398d58, 0x9dfd, 0x4103, {0xbf, 0x94, 0x78, 0xc6, 0xf4, 0xfe, 0x71, 0x2f } \\r
+ }\r
+\r
+typedef struct {\r
+ EFI_PEI_RESET_SYSTEM ResetSystem;\r
+} EFI_PEI_RESET_PPI;\r
+\r
+extern EFI_GUID gEfiPeiResetPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Sec Platform Information PPI.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: SecPlatformInformation.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __SEC_PLATFORM_INFORMATION_PPI_H__\r
+#define __SEC_PLATFORM_INFORMATION_PPI_H__\r
+\r
+#define EFI_SEC_PLATFORM_INFORMATION_GUID \\r
+ { \\r
+ 0x6f8c2b35, 0xfef4, 0x448d, {0x82, 0x56, 0xe1, 0x1b, 0x19, 0xd6, 0x10, 0x77 } \\r
+ }\r
+\r
+typedef struct _EFI_SEC_PLATFORM_INFORMATION_PPI EFI_SEC_PLATFORM_INFORMATION_PPI;\r
+\r
+\r
+///\r
+/// EFI_HEALTH_FLAGS\r
+///\r
+typedef union {\r
+ struct {\r
+ UINT32 Status : 2;\r
+ UINT32 Tested : 1;\r
+ UINT32 Reserved1 :13;\r
+ UINT32 VirtualMemoryUnavailable : 1;\r
+ UINT32 Ia32ExecutionUnavailable : 1;\r
+ UINT32 FloatingPointUnavailable : 1;\r
+ UINT32 MiscFeaturesUnavailable : 1;\r
+ UINT32 Reserved2 :12;\r
+ } Bits;\r
+ UINT32 Uint32;\r
+} EFI_HEALTH_FLAGS;\r
+\r
+typedef struct {\r
+ EFI_HEALTH_FLAGS HealthFlags;\r
+} EFI_SEC_PLATFORM_INFORMATION_RECORD;\r
+\r
+\r
+\r
+/**\r
+ This interface conveys state information out of the Security (SEC) phase into PEI.\r
+\r
+ @param PeiServices Pointer to the PEI Services Table.\r
+ @param StructureSize Pointer to the variable describing size of the input buffer.\r
+ @param PlatformInformationRecord Pointer to the EFI_SEC_PLATFORM_INFORMATION_RECORD.\r
+\r
+ @retval EFI_SUCCESS The data was successfully returned.\r
+ @retval EFI_BUFFER_TOO_SMALL The buffer was too small.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_SEC_PLATFORM_INFORMATION) (\r
+ IN CONST EFI_PEI_SERVICES **PeiServices,\r
+ IN OUT UINT64 *StructureSize,\r
+ OUT EFI_SEC_PLATFORM_INFORMATION_RECORD *PlatformInformationRecord\r
+);\r
+\r
+\r
+/**\r
+ Ppi Description:\r
+\r
+ @param Name\r
+\r
+**/\r
+struct _EFI_SEC_PLATFORM_INFORMATION_PPI {\r
+ EFI_SEC_PLATFORM_INFORMATION PlatformInformation;\r
+};\r
+\r
+\r
+extern EFI_GUID gEfiSecPlatformInformationPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Security Architectural PPI.\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: Security.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.0.\r
+\r
+**/\r
+\r
+#ifndef __SECURITY_PPI_H__\r
+#define __SECURITY_PPI_H__\r
+\r
+#define EFI_PEI_SECURITY_PPI_GUID \\r
+ { \\r
+ 0x1388066e, 0x3a57, 0x4efa, {0x98, 0xf3, 0xc1, 0x2f, 0x3a, 0x95, 0x8a, 0x29 } \\r
+ }\r
+\r
+typedef struct _EFI_PEI_SECURITY_PPI EFI_PEI_SECURITY_PPI;\r
+\r
+/**\r
+ Allows the platform builder to implement a security policy in response \r
+ to varying file authentication states.\r
+\r
+ @param PeiServices Pointer to the PEI Services Table.\r
+ @param This Interface pointer that implements the particular EFI_PEI_SECURITY_PPI instance.\r
+ @param AuthenticationStatus \r
+ Status returned by the verification service as part of section extraction.\r
+ @param FfsFileHeader Pointer to the file under review.\r
+ @param DeferExecution Pointer to a variable that alerts the PEI Foundation to defer execution of a PEIM.\r
+\r
+ @retval EFI_SUCCESS The service performed its action successfully.\r
+ @retval EFI_SECURITY_VIOLATION The object cannot be trusted\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SECURITY_AUTHENTICATION_STATE) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_SECURITY_PPI *This,\r
+ IN UINT32 AuthenticationStatus,\r
+ IN EFI_FFS_FILE_HEADER *FfsFileHeader,\r
+ IN OUT BOOLEAN *StartCrisisRecovery\r
+ );\r
+\r
+/**\r
+ @par Ppi Description:\r
+ This PPI is installed by some platform PEIM that abstracts the security \r
+ policy to the PEI Foundation, namely the case of a PEIM's authentication \r
+ state being returned during the PEI section extraction process. \r
+\r
+ @param AuthenticationState\r
+ Allows the platform builder to implement a security policy in response \r
+ to varying file authentication states.\r
+\r
+**/\r
+struct _EFI_PEI_SECURITY_PPI {\r
+ EFI_PEI_SECURITY_AUTHENTICATION_STATE AuthenticationState;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiSecurityPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Smbus2 PPI.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: Smbus2.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00\r
+\r
+**/\r
+\r
+#ifndef _PEI_SMBUS2_PPI_H\r
+#define _PEI_SMBUS2_PPI_H\r
+\r
+#include <IndustryStandard/SmBus.h>\r
+\r
+#define EFI_PEI_SMBUS2_PPI_GUID \\r
+ { 0x9ca93627, 0xb65b, 0x4324, { 0xa2, 0x2, 0xc0, 0xb4, 0x61, 0x76, 0x45, 0x43 } }\r
+\r
+\r
+typedef struct _EFI_PEI_SMBUS2_PPI EFI_PEI_SMBUS2_PPI;\r
+\r
+//\r
+// EFI_SMBUS_DEVICE_COMMAND\r
+//\r
+typedef UINTN EFI_SMBUS_DEVICE_COMMAND;\r
+\r
+\r
+/*\r
+ Executes an SMBus operation to an SMBus controller.\r
+\r
+ @param This A pointer to the EFI_PEI_SMBUS2_PPI instance.\r
+ @param SlaveAddress The SMBUS hardware address to which the SMBUS device is preassigned or\r
+ allocated.\r
+ @param Command This command is transmitted by the SMBus host controller to the SMBus slave \r
+ device and the interpretation is SMBus slave device specific. \r
+ It can mean the offset to a list of functions inside \r
+ an SMBus slave device. Not all operations or slave devices support\r
+ this command's registers.\r
+\r
+ @param Operation Signifies which particular SMBus hardware protocol instance that it \r
+ will use to execute the SMBus transactions. \r
+ This SMBus hardware protocol is defined by the System Management Bus (SMBus) \r
+ Specification and is not related to UEFI.\r
+\r
+ @param PecCheck Defines if Packet Error Code (PEC) checking is required for this operation.\r
+\r
+ @param Length Signifies the number of bytes that this operation will do. \r
+ The maximum number of bytes can be revision specific and operation specific.\r
+ This parameter will contain the actual number of bytes that are executed\r
+ for this operation. Not all operations require this argument.\r
+\r
+ @param Buffer Contains the value of data to execute to the SMBus slave device. \r
+ Not all operations require this argument. \r
+ The length of this buffer is identified by Length.\r
+\r
+\r
+ @retval EFI_SUCCESS The last data that was returned from the access\r
+ matched the poll exit criteria.\r
+ @retval EFI_CRC_ERROR The checksum is not correct (PEC is incorrect)\r
+ @retval EFI_TIMEOUT Timeout expired before the operation was completed.\r
+ Timeout is determined by the SMBus host controller device.\r
+ @retval EFI_OUT_OF_RESOURCES The request could not be completed\r
+ due to a lack of resources.\r
+ @retval EFI_DEVICE_ERROR The request was not completed because\r
+ a failure reflected in the Host Status Register bit.\r
+ @retval EFI_INVALID_PARAMETER Operation is not defined in EFI_SMBUS_OPERATION.\r
+ Or Length/Buffer is NULL for operations except for EfiSmbusQuickRead and\r
+ EfiSmbusQuickWrite. Length is outside the range of valid values.\r
+ @retval EFI_UNSUPPORTED The SMBus operation or PEC is not supported.\r
+ @retval EFI_BUFFER_TOO_SMALL Buffer is not sufficient for this operation.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS2_PPI_EXECUTE_OPERATION) (\r
+ IN CONST EFI_PEI_SMBUS2_PPI *This,\r
+ IN CONST EFI_SMBUS_DEVICE_ADDRESS SlaveAddress,\r
+ IN CONST EFI_SMBUS_DEVICE_COMMAND Command,\r
+ IN CONST EFI_SMBUS_OPERATION Operation,\r
+ IN CONST BOOLEAN PecCheck,\r
+ IN OUT UINTN *Length,\r
+ IN OUT VOID *Buffer\r
+);\r
+\r
+\r
+typedef struct {\r
+ UINT32 VendorSpecificId;\r
+ UINT16 SubsystemDeviceId;\r
+ UINT16 SubsystemVendorId;\r
+ UINT16 Interface;\r
+ UINT16 DeviceId;\r
+ UINT16 VendorId;\r
+ UINT8 VendorRevision;\r
+ UINT8 DeviceCapabilities;\r
+} EFI_SMBUS_UDID;\r
+\r
+/**\r
+ CallBack function can be registered in EFI_PEI_SMBUS_PPI_NOTIFY.\r
+\r
+ @param This A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+ @param SlaveAddress The SMBUS hardware address to which the SMBUS\r
+ device is preassigned or allocated.\r
+ @param Data Data of the SMBus host notify command that\r
+ the caller wants to be called.\r
+\r
+ @return Status Code\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS_NOTIFY2_FUNCTION) (\r
+ IN CONST EFI_PEI_SMBUS2_PPI *SmbusPpi,\r
+ IN CONST EFI_SMBUS_DEVICE_ADDRESS SlaveAddress,\r
+ IN CONST UINTN Data\r
+);\r
+/**\r
+ The ArpDevice() function enumerates the entire bus or enumerates a specific \r
+ device that is identified by SmbusUdid. \r
+\r
+ @param This A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+ @param ArpAll A Boolean expression that indicates if the host drivers need\r
+ to enumerate all the devices or enumerate only the device that is identified\r
+ by SmbusUdid. If ArpAll is TRUE, SmbusUdid and SlaveAddress are optional.\r
+ If ArpAll is FALSE, ArpDevice will enumerate SmbusUdid and the address\r
+ will be at SlaveAddress.\r
+ @param SmbusUdid The targeted SMBus Unique Device Identifier (UDID).\r
+ The UDID may not exist for SMBus devices with fixed addresses.\r
+ @param SlaveAddress The new SMBus address for the slave device for\r
+ which the operation is targeted.\r
+\r
+ @retval EFI_SUCCESS The SMBus slave device address was set.\r
+ @retval EFI_INVALID_PARAMETER SlaveAddress is NULL.\r
+ @retval EFI_OUT_OF_RESOURCES The request could not be completed\r
+ due to a lack of resources.\r
+ @retval EFI_TIMEOUT The SMBus slave device did not respond.\r
+ @retval EFI_DEVICE_ERROR The request was not completed because the transaction failed.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS2_PPI_ARP_DEVICE) (\r
+ IN CONST EFI_PEI_SMBUS2_PPI *This,\r
+ IN CONST BOOLEAN ArpAll,\r
+ IN CONST EFI_SMBUS_UDID *SmbusUdid, OPTIONAL\r
+ IN OUT EFI_SMBUS_DEVICE_ADDRESS *SlaveAddress OPTIONAL\r
+);\r
+\r
+\r
+typedef struct {\r
+ EFI_SMBUS_DEVICE_ADDRESS SmbusDeviceAddress;\r
+ EFI_SMBUS_UDID SmbusDeviceUdid;\r
+} EFI_SMBUS_DEVICE_MAP;\r
+\r
+/**\r
+ The GetArpMap() function returns the mapping of all the SMBus devices \r
+ that are enumerated by the SMBus host driver. \r
+\r
+ @param This A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+ @param Length Size of the buffer that contains the SMBus device map.\r
+ @param SmbusDeviceMap The pointer to the device map as enumerated\r
+ by the SMBus controller driver.\r
+\r
+ @retval EFI_SUCCESS The device map was returned correctly in the buffer.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS2_PPI_GET_ARP_MAP) (\r
+ IN CONST EFI_PEI_SMBUS2_PPI *This,\r
+ IN OUT UINTN *Length,\r
+ IN OUT EFI_SMBUS_DEVICE_MAP **SmbusDeviceMap\r
+);\r
+\r
+\r
+/**\r
+ The Notify() function registers all the callback functions to allow the \r
+ bus driver to call these functions when the SlaveAddress/Data pair happens.\r
+\r
+ @param PeiServices A pointer to the system PEI Services Table.\r
+ @param This A pointer to the EFI_PEI_SMBUS_PPI instance.\r
+ @param SlaveAddress Address that the host controller detects as\r
+ sending a message and calls all the registered functions.\r
+ @param Data Data that the host controller detects as sending a message\r
+ and calls all the registered functions.\r
+ @param NotifyFunction The function to call when the bus driver\r
+ detects the SlaveAddress and Data pair.\r
+\r
+ @retval EFI_SUCCESS NotifyFunction has been registered.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_SMBUS2_PPI_NOTIFY) (\r
+ IN CONST EFI_PEI_SMBUS2_PPI *This,\r
+ IN CONST EFI_SMBUS_DEVICE_ADDRESS SlaveAddress,\r
+ IN CONST UINTN Data,\r
+ IN CONST EFI_PEI_SMBUS_NOTIFY2_FUNCTION NotifyFunction\r
+);\r
+\r
+/**\r
+ @par Ppi Description:\r
+ Provides the basic I/O interfaces that a PEIM uses to access \r
+ its SMBus controller and the slave devices attached to it.\r
+\r
+ @param Execute\r
+ Executes the SMBus operation to an SMBus slave device.\r
+\r
+ @param ArpDevice\r
+ Allows an SMBus 2.0 device(s) to be Address Resolution Protocol (ARP)\r
+\r
+ @param GetArpMap\r
+ Allows a PEIM to retrieve the address that was allocated by the SMBus \r
+ host controller during enumeration/ARP.\r
+\r
+ @param Notify\r
+ Allows a driver to register for a callback to the SMBus host \r
+ controller driver when the bus issues a notification to the bus controller PEIM.\r
+\r
+ @param Identifier\r
+ Identifier which uniquely identifies this SMBus controller in a system.\r
+\r
+**/\r
+struct _EFI_PEI_SMBUS2_PPI {\r
+ EFI_PEI_SMBUS2_PPI_EXECUTE_OPERATION Execute;\r
+ EFI_PEI_SMBUS2_PPI_ARP_DEVICE ArpDevice;\r
+ EFI_PEI_SMBUS2_PPI_GET_ARP_MAP GetArpMap;\r
+ EFI_PEI_SMBUS2_PPI_NOTIFY Notify;\r
+ EFI_GUID Identifier;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiSmbus2PpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Stall PPI.\r
+\r
+ This code abstracts the PEI core to provide Stall services.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: Stall.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __STALL_PPI_H__\r
+#define __STALL_PPI_H__\r
+\r
+#define EFI_PEI_STALL_PPI_GUID \\r
+ { 0x1f4c6f90, 0xb06b, 0x48d8, {0xa2, 0x01, 0xba, 0xe5, 0xf1, 0xcd, 0x7d, 0x56 } }\r
+\r
+typedef struct _EFI_PEI_STALL_PPI EFI_PEI_STALL_PPI;\r
+\r
+/**\r
+ The Stall() function provides a blocking stall for at least the number \r
+ of microseconds stipulated in the final argument of the API.\r
+\r
+ @param PeiServices An indirect pointer to the PEI Services Table\r
+ published by the PEI Foundation.\r
+ @param This Pointer to the local data for the interface.\r
+ @param Microseconds Number of microseconds for which to stall.\r
+\r
+ @retval EFI_SUCCESS The service provided at least the required delay.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI *EFI_PEI_STALL) (\r
+ IN EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PEI_STALL_PPI *This,\r
+ IN UINTN Microseconds\r
+ );\r
+\r
+/**\r
+ @par Ppi Description:\r
+ This service provides a simple, blocking stall with platform-specific resolution. \r
+\r
+ @param Resolution\r
+ The resolution in microseconds of the stall services.\r
+\r
+ @param Stall\r
+ The actual stall procedure call. \r
+\r
+**/\r
+struct _EFI_PEI_STALL_PPI {\r
+ UINTN Resolution;\r
+ EFI_PEI_STALL Stall;\r
+};\r
+\r
+extern EFI_GUID gEfiPeiStallPpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/** @file\r
+ This file declares Status Code PPI.\r
+\r
+ Copyright (c) 2006, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: StatusCode.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __STATUS_CODE_PPI_H__\r
+#define __STATUS_CODE_PPI_H__\r
+\r
+#define EFI_PEI_REPORT_PROGRESS_CODE_PPI_GUID \\r
+ { 0x229832d3, 0x7a30, 0x4b36, {0xb8, 0x27, 0xf4, 0xc, 0xb7, 0xd4, 0x54, 0x36 } }\r
+\r
+/**\r
+ @par Ppi Description:\r
+ This ppi provides the sevice to report status code. There can be only one instance \r
+ of this service in the system.\r
+\r
+ @param ReportStatusCode\r
+ Service that allows PEIMs to report status codes. This function is defined in Peicis.h\r
+\r
+**/\r
+typedef struct {\r
+ EFI_PEI_REPORT_STATUS_CODE ReportStatusCode;\r
+} EFI_PEI_PROGRESS_CODE_PPI;\r
+\r
+extern EFI_GUID gEfiPeiStatusCodePpiGuid;\r
+\r
+#endif\r
--- /dev/null
+/* @file\r
+ This file declares Temporary RAM Support PPI.\r
+\r
+ Copyright (c) 2006 - 2007, Intel Corporation \r
+ All rights reserved. This program and the accompanying materials \r
+ are licensed and made available under the terms and conditions of the BSD License \r
+ which accompanies this distribution. The full text of the license may be found at \r
+ http://opensource.org/licenses/bsd-license.php \r
+\r
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
+\r
+ Module Name: TemporaryRamSupport.h\r
+\r
+ @par Revision Reference:\r
+ This PPI is defined in PI.\r
+ Version 1.00.\r
+\r
+**/\r
+\r
+#ifndef __TEMPORARY_RAM_SUPPORT_H__\r
+#define __TEMPORARY_RAM_SUPPORT_H__\r
+\r
+#define TEMPORARY_RAM_SUPPORT_PPI_GUID \\r
+ { 0xdbe23aa9, 0xa345, 0x4b97, {0x85, 0xb6, 0xb2, 0x26, 0xf1, 0x61, 0x73, 0x89} }\r
+\r
+\r
+/*\r
+ This service of the TEMPORARY_RAM_SUPPORT_PPI that migrates temporary RAM into\r
+ permanent memory.\r
+\r
+ @param PeiServices Pointer to the PEI Services Table.\r
+\r
+ @param TemporaryMemoryBase Source Address in temporary memory from which the SEC or PEIM will copy the\r
+ Temporary RAM contents.\r
+\r
+ @param PermanentMemoryBase Destination Address in permanent memory into which the SEC or PEIM will copy the\r
+ Temporary RAM contents.\r
+\r
+ @param CopySize Amount of memory to migrate from temporary to permanent memory.\r
+\r
+\r
+\r
+ @retval EFI_SUCCESS The data was successfully returned.\r
+\r
+ @retval EFI_INVALID_PARAMETER PermanentMemoryBase + CopySize >\r
+ TemporaryMemoryBase when TemporaryMemoryBase >\r
+ PermanentMemoryBase.\r
+\r
+**/\r
+typedef\r
+EFI_STATUS\r
+(EFIAPI * TEMPORARY_RAM_MIGRATION) (\r
+ IN CONST EFI_PEI_SERVICES **PeiServices,\r
+ IN EFI_PHYSICAL_ADDRESS TemporaryMemoryBase,\r
+ IN EFI_PHYSICAL_ADDRESS PermanentMemoryBase,\r
+ IN UINTN CopySize\r
+);\r
+\r
+\r
+typedef struct {\r
+ TEMPORARY_RAM_MIGRATION TemporaryRamMigration;\r
+} TEMPORARY_RAM_SUPPORT_PPI;\r
+\r
+extern EFI_GUID gEfiPeiTemporaryRamSupportPpiGuid;\r
+\r
+#endif\r