]>
Commit | Line | Data |
---|---|---|
1 | /** @file\r | |
2 | Include file for definitions in the Intel Platform Innovation Framework for EFI\r | |
3 | Pre-EFI Initialization Core Interface Specification (PEI CIS) Version 0.91.\r | |
4 | \r | |
5 | Copyright (c) 2006 - 2009, Intel Corporation \r | |
6 | All rights reserved. This program and the accompanying materials \r | |
7 | are licensed and made available under the terms and conditions of the BSD License \r | |
8 | which accompanies this distribution. The full text of the license may be found at \r | |
9 | http://opensource.org/licenses/bsd-license.php \r | |
10 | \r | |
11 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
12 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
13 | \r | |
14 | **/\r | |
15 | \r | |
16 | #ifndef __PEICIS_H__\r | |
17 | #define __PEICIS_H__\r | |
18 | \r | |
19 | #include <PiPei.h>\r | |
20 | #include <Ppi/PciCfg.h>\r | |
21 | \r | |
22 | typedef struct _FRAMEWORK_EFI_PEI_SERVICES FRAMEWORK_EFI_PEI_SERVICES;\r | |
23 | \r | |
24 | /**\r | |
25 | The PEI Dispatcher will invoke each PEIM one time. During this pass, the PEI \r | |
26 | Dispatcher will pass control to the PEIM at the AddressOfEntryPoint in the PE Header. \r | |
27 | \r | |
28 | @param FfsHeader Pointer to the FFS file header.\r | |
29 | @param PeiServices Describes the list of possible PEI Services.\r | |
30 | \r | |
31 | @return Status code\r | |
32 | \r | |
33 | **/\r | |
34 | typedef\r | |
35 | EFI_STATUS\r | |
36 | (EFIAPI *EFI_PEIM_ENTRY_POINT)(\r | |
37 | IN EFI_FFS_FILE_HEADER *FfsHeader,\r | |
38 | IN EFI_PEI_SERVICES **PeiServices\r | |
39 | );\r | |
40 | \r | |
41 | /**\r | |
42 | The purpose of the service is to abstract the capability of the PEI \r | |
43 | Foundation to discover instances of firmware volumes in the system. \r | |
44 | Given the input file pointer, this service searches for the next \r | |
45 | matching file in the Firmware File System (FFS) volume.\r | |
46 | \r | |
47 | @param PeiServices An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.\r | |
48 | @param Instance This instance of the firmware volume to find. The value 0 is the Boot Firmware Volume (BFV).\r | |
49 | @param FwVolHeader Pointer to the firmware volume header of the volume to return.\r | |
50 | \r | |
51 | @retval EFI_SUCCESS The volume was found.\r | |
52 | @retval EFI_NOT_FOUND The volume was not found.\r | |
53 | @retval EFI_INVALID_PARAMETER FwVolHeader is NULL\r | |
54 | \r | |
55 | **/\r | |
56 | typedef\r | |
57 | EFI_STATUS\r | |
58 | (EFIAPI *EFI_PEI_FFS_FIND_NEXT_VOLUME)(\r | |
59 | IN FRAMEWORK_EFI_PEI_SERVICES **PeiServices,\r | |
60 | IN UINTN Instance,\r | |
61 | IN OUT EFI_FIRMWARE_VOLUME_HEADER **FwVolHeader\r | |
62 | );\r | |
63 | \r | |
64 | /**\r | |
65 | The purpose of the service is to abstract the capability of the PEI \r | |
66 | Foundation to discover instances of firmware files in the system. \r | |
67 | Given the input file pointer, this service searches for the next matching \r | |
68 | file in the Firmware File System (FFS) volume.\r | |
69 | \r | |
70 | @param PeiServices An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.\r | |
71 | @param SearchType A filter to find files only of this type.\r | |
72 | @param FwVolHeader Pointer to the firmware volume header of the volume to search.This parameter \r | |
73 | must point to a valid FFS volume.\r | |
74 | @param FileHeader Pointer to the current file from which to begin searching.This pointer will be \r | |
75 | updated upon return to reflect the file found.\r | |
76 | \r | |
77 | @retval EFI_SUCCESS The file was found.\r | |
78 | @retval EFI_NOT_FOUND The file was not found.\r | |
79 | @retval EFI_NOT_FOUND The header checksum was not zero.\r | |
80 | \r | |
81 | **/\r | |
82 | typedef\r | |
83 | EFI_STATUS\r | |
84 | (EFIAPI *EFI_PEI_FFS_FIND_NEXT_FILE)(\r | |
85 | IN FRAMEWORK_EFI_PEI_SERVICES **PeiServices,\r | |
86 | IN EFI_FV_FILETYPE SearchType,\r | |
87 | IN EFI_FIRMWARE_VOLUME_HEADER *FwVolHeader,\r | |
88 | IN OUT EFI_FFS_FILE_HEADER **FileHeader\r | |
89 | );\r | |
90 | \r | |
91 | /**\r | |
92 | Given the input file pointer, this service searches for the next \r | |
93 | matching file in the Firmware File System (FFS) volume. \r | |
94 | \r | |
95 | @param PeiServices An indirect pointer to the EFI_PEI_SERVICES table published by the PEI Foundation.\r | |
96 | @param SectionType The value of the section type to find.\r | |
97 | @param FfsFileHeader A pointer to the file header that contains the set of sections to be searched.\r | |
98 | @param SectionData A pointer to the discovered section, if successful.\r | |
99 | \r | |
100 | @retval EFI_SUCCESS The section was found.\r | |
101 | @retval EFI_NOT_FOUND The section was not found.\r | |
102 | \r | |
103 | **/\r | |
104 | typedef\r | |
105 | EFI_STATUS\r | |
106 | (EFIAPI *EFI_PEI_FFS_FIND_SECTION_DATA)(\r | |
107 | IN FRAMEWORK_EFI_PEI_SERVICES **PeiServices,\r | |
108 | IN EFI_SECTION_TYPE SectionType,\r | |
109 | IN EFI_FFS_FILE_HEADER *FfsFileHeader,\r | |
110 | IN OUT VOID **SectionData\r | |
111 | );\r | |
112 | \r | |
113 | ///\r | |
114 | /// FRAMEWORK_EFI_PEI_SERVICES is a collection of functions whose implementation is provided by the PEI\r | |
115 | /// Foundation. The table is located in the temporary or permanent memory, depending upon the capabilities \r | |
116 | /// and phase of execution of PEI.\r | |
117 | /// \r | |
118 | /// These services fall into various classes, including the following:\r | |
119 | /// - Managing the boot mode\r | |
120 | /// - Allocating both early and permanent memory\r | |
121 | /// - Supporting the Firmware File System (FFS)\r | |
122 | /// - Abstracting the PPI database abstraction\r | |
123 | /// - Creating Hand-Off Blocks (HOBs)\r | |
124 | /// \r | |
125 | struct _FRAMEWORK_EFI_PEI_SERVICES {\r | |
126 | EFI_TABLE_HEADER Hdr;\r | |
127 | //\r | |
128 | // PPI Functions\r | |
129 | //\r | |
130 | EFI_PEI_INSTALL_PPI InstallPpi;\r | |
131 | EFI_PEI_REINSTALL_PPI ReInstallPpi;\r | |
132 | EFI_PEI_LOCATE_PPI LocatePpi;\r | |
133 | EFI_PEI_NOTIFY_PPI NotifyPpi;\r | |
134 | //\r | |
135 | // Boot Mode Functions\r | |
136 | //\r | |
137 | EFI_PEI_GET_BOOT_MODE GetBootMode;\r | |
138 | EFI_PEI_SET_BOOT_MODE SetBootMode;\r | |
139 | //\r | |
140 | // HOB Functions\r | |
141 | //\r | |
142 | EFI_PEI_GET_HOB_LIST GetHobList;\r | |
143 | EFI_PEI_CREATE_HOB CreateHob;\r | |
144 | //\r | |
145 | // Firmware Volume Functions\r | |
146 | //\r | |
147 | EFI_PEI_FFS_FIND_NEXT_VOLUME FfsFindNextVolume;\r | |
148 | EFI_PEI_FFS_FIND_NEXT_FILE FfsFindNextFile;\r | |
149 | EFI_PEI_FFS_FIND_SECTION_DATA FfsFindSectionData;\r | |
150 | //\r | |
151 | // PEI Memory Functions\r | |
152 | //\r | |
153 | EFI_PEI_INSTALL_PEI_MEMORY InstallPeiMemory;\r | |
154 | EFI_PEI_ALLOCATE_PAGES AllocatePages;\r | |
155 | EFI_PEI_ALLOCATE_POOL AllocatePool;\r | |
156 | EFI_PEI_COPY_MEM CopyMem;\r | |
157 | EFI_PEI_SET_MEM SetMem;\r | |
158 | //\r | |
159 | // Status Code\r | |
160 | //\r | |
161 | EFI_PEI_REPORT_STATUS_CODE ReportStatusCode;\r | |
162 | //\r | |
163 | // Reset\r | |
164 | //\r | |
165 | EFI_PEI_RESET_SYSTEM ResetSystem;\r | |
166 | //\r | |
167 | // (the following interfaces are installed by publishing PEIM)\r | |
168 | //\r | |
169 | // I/O Abstractions\r | |
170 | //\r | |
171 | EFI_PEI_CPU_IO_PPI *CpuIo;\r | |
172 | EFI_PEI_PCI_CFG_PPI *PciCfg;\r | |
173 | };\r | |
174 | \r | |
175 | #endif \r | |
176 | \r |