2 PI PEI master include file. This file should match the PI spec.
4 Copyright (c) 2006 - 2007, Intel Corporation
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
13 @par Revision Reference:
22 #include <Ppi/PciCfg.h>
24 typedef struct _FRAMEWORK_EFI_PEI_SERVICES FRAMEWORK_EFI_PEI_SERVICES
;
27 The PEI Dispatcher will invoke each PEIM one time. During this pass, the PEI
28 Dispatcher will pass control to the PEIM at the AddressOfEntryPoint in the PE Header.
30 @param FfsHeader Pointer to the FFS file header.
31 @param PeiServices Describes the list of possible PEI Services.
38 (EFIAPI
*EFI_PEIM_ENTRY_POINT
)(
39 IN EFI_FFS_FILE_HEADER
*FfsHeader
,
40 IN EFI_PEI_SERVICES
**PeiServices
44 The purpose of the service is to abstract the capability of the PEI
45 Foundation to discover instances of firmware volumes in the system.
46 Given the input file pointer, this service searches for the next
47 matching file in the Firmware File System (FFS) volume.
49 @param PeiServices An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.
50 @param Instance This instance of the firmware volume to find. The value 0 is the Boot Firmware Volume (BFV).
51 @param FwVolHeader Pointer to the firmware volume header of the volume to return.
53 @retval EFI_SUCCESS The volume was found.
54 @retval EFI_NOT_FOUND The volume was not found.
55 @retval EFI_INVALID_PARAMETER FwVolHeader is NULL
60 (EFIAPI
*EFI_PEI_FFS_FIND_NEXT_VOLUME
)(
61 IN FRAMEWORK_EFI_PEI_SERVICES
**PeiServices
,
63 IN OUT EFI_FIRMWARE_VOLUME_HEADER
**FwVolHeader
67 The purpose of the service is to abstract the capability of the PEI
68 Foundation to discover instances of firmware files in the system.
69 Given the input file pointer, this service searches for the next matching
70 file in the Firmware File System (FFS) volume.
72 @param PeiServices An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.
73 @param SearchType A filter to find files only of this type.
74 @param FwVolHeader Pointer to the firmware volume header of the volume to search.This parameter
75 must point to a valid FFS volume.
76 @param FileHeader Pointer to the current file from which to begin searching.This pointer will be
77 updated upon return to reflect the file found.
79 @retval EFI_SUCCESS The file was found.
80 @retval EFI_NOT_FOUND The file was not found.
81 @retval EFI_NOT_FOUND The header checksum was not zero.
86 (EFIAPI
*EFI_PEI_FFS_FIND_NEXT_FILE
)(
87 IN FRAMEWORK_EFI_PEI_SERVICES
**PeiServices
,
88 IN EFI_FV_FILETYPE SearchType
,
89 IN EFI_FIRMWARE_VOLUME_HEADER
*FwVolHeader
,
90 IN OUT EFI_FFS_FILE_HEADER
**FileHeader
94 Given the input file pointer, this service searches for the next
95 matching file in the Firmware File System (FFS) volume.
97 @param PeiServices An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.
98 @param SectionType The value of the section type to find.
99 @param FfsFileHeader A pointer to the file header that contains the set of sections to be searched.
100 @param SectionData A pointer to the discovered section, if successful.
102 @retval EFI_SUCCESS The section was found.
103 @retval EFI_NOT_FOUND The section was not found.
108 (EFIAPI
*EFI_PEI_FFS_FIND_SECTION_DATA
)(
109 IN FRAMEWORK_EFI_PEI_SERVICES
**PeiServices
,
110 IN EFI_SECTION_TYPE SectionType
,
111 IN EFI_FFS_FILE_HEADER
*FfsFileHeader
,
112 IN OUT VOID
**SectionData
115 struct _FRAMEWORK_EFI_PEI_SERVICES
{
116 EFI_TABLE_HEADER Hdr
;
120 EFI_PEI_INSTALL_PPI InstallPpi
;
121 EFI_PEI_REINSTALL_PPI ReInstallPpi
;
122 EFI_PEI_LOCATE_PPI LocatePpi
;
123 EFI_PEI_NOTIFY_PPI NotifyPpi
;
125 // Boot Mode Functions
127 EFI_PEI_GET_BOOT_MODE GetBootMode
;
128 EFI_PEI_SET_BOOT_MODE SetBootMode
;
132 EFI_PEI_GET_HOB_LIST GetHobList
;
133 EFI_PEI_CREATE_HOB CreateHob
;
135 // Firmware Volume Functions
137 EFI_PEI_FFS_FIND_NEXT_VOLUME FfsFindNextVolume
;
138 EFI_PEI_FFS_FIND_NEXT_FILE FfsFindNextFile
;
139 EFI_PEI_FFS_FIND_SECTION_DATA FfsFindSectionData
;
141 // PEI Memory Functions
143 EFI_PEI_INSTALL_PEI_MEMORY InstallPeiMemory
;
144 EFI_PEI_ALLOCATE_PAGES AllocatePages
;
145 EFI_PEI_ALLOCATE_POOL AllocatePool
;
146 EFI_PEI_COPY_MEM CopyMem
;
147 EFI_PEI_SET_MEM SetMem
;
151 EFI_PEI_REPORT_STATUS_CODE ReportStatusCode
;
155 EFI_PEI_RESET_SYSTEM ResetSystem
;
157 // (the following interfaces are installed by publishing PEIM)
161 EFI_PEI_CPU_IO_PPI
*CpuIo
;
162 EFI_PEI_PCI_CFG_PPI
*PciCfg
;
166 UINTN BootFirmwareVolume
;
167 UINTN SizeOfCacheAsRam
;
168 EFI_PEI_PPI_DESCRIPTOR
*DispatchTable
;
169 } EFI_PEI_STARTUP_DESCRIPTOR
;