c9093a06 |
1 | /*++\r |
2 | \r |
3 | Copyright (c) 2006, Intel Corporation \r |
4 | All rights reserved. This program and the accompanying materials \r |
5 | are licensed and made available under the terms and conditions of the BSD License \r |
6 | which accompanies this distribution. The full text of the license may be found at \r |
7 | http://opensource.org/licenses/bsd-license.php \r |
8 | \r |
9 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r |
10 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r |
11 | \r |
12 | Module Name:\r |
13 | \r |
14 | UnixPeiLoadFile.h\r |
15 | \r |
16 | Abstract:\r |
17 | \r |
18 | Unix Load File PPI.\r |
19 | \r |
20 | When the PEI core is done it calls the DXE IPL via PPI\r |
21 | \r |
22 | --*/\r |
23 | \r |
24 | #ifndef __UNIX_PEI_LOAD_FILE_H__\r |
25 | #define __UNIX_PEI_LOAD_FILE_H__\r |
26 | \r |
27 | #include <UnixDxe.h>\r |
28 | \r |
29 | #define UNIX_PEI_LOAD_FILE_GUID \\r |
30 | { \\r |
31 | 0xf2f48768, 0x8985, 0x11db, {0xb8, 0xda, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } \ |
32 | }\r |
33 | \r |
34 | typedef\r |
35 | EFI_STATUS\r |
36 | (EFIAPI *UNIX_PEI_LOAD_FILE) (\r |
37 | VOID *Pe32Data,\r |
38 | EFI_PHYSICAL_ADDRESS *ImageAddress,\r |
39 | UINT64 *ImageSize,\r |
40 | EFI_PHYSICAL_ADDRESS *EntryPoint\r |
41 | );\r |
42 | \r |
43 | /*++\r |
44 | \r |
45 | Routine Description:\r |
46 | Loads and relocates a PE/COFF image into memory.\r |
47 | \r |
48 | Arguments:\r |
49 | Pe32Data - The base address of the PE/COFF file that is to be loaded and relocated\r |
50 | ImageAddress - The base address of the relocated PE/COFF image\r |
51 | ImageSize - The size of the relocated PE/COFF image\r |
52 | EntryPoint - The entry point of the relocated PE/COFF image\r |
53 | \r |
54 | Returns:\r |
55 | EFI_SUCCESS - The file was loaded and relocated\r |
56 | EFI_OUT_OF_RESOURCES - There was not enough memory to load and relocate the PE/COFF file\r |
57 | \r |
58 | --*/\r |
59 | typedef struct {\r |
60 | UNIX_PEI_LOAD_FILE PeiLoadFileService;\r |
61 | } UNIX_PEI_LOAD_FILE_PPI;\r |
62 | \r |
63 | extern EFI_GUID gUnixPeiLoadFilePpiGuid;\r |
64 | \r |
65 | #endif\r |