]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Core/Dxe/DxeMain.h
Don't align image address for TeImage, because TeImage section alignment is undefined.
[mirror_edk2.git] / MdeModulePkg / Core / Dxe / DxeMain.h
index 6e61242149ccba0debd4724618baae72379a6aaa..30fffb9f38fee673489492d286e2a0fb637c0fd9 100644 (file)
@@ -76,7 +76,9 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #include <Library/PeCoffLib.h>\r
 #include <Library/PcdLib.h>\r
 #include <Library/MemoryAllocationLib.h>\r
+#include <Library/DevicePathLib.h>\r
 #include <Library/UefiBootServicesTableLib.h>\r
+#include <Library/ReportStatusCodeLib.h>\r
 \r
 #include "DebugImageInfo.h"\r
 #include "Library.h"\r
@@ -85,14 +87,8 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #include "Gcd.h"\r
 #include "Imem.h"\r
 #include "Image.h"\r
-#include "Exec.h"\r
-#include "Hand.h"\r
-\r
-\r
-//\r
-// Modifier for EFI DXE Services\r
-//\r
-#define EFI_DXESERVICE\r
+#include "Event.h"\r
+#include "Handle.h"\r
 \r
 //\r
 // attributes for reserved memory before it is promoted to system memory\r
@@ -110,7 +106,10 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 ///\r
 /// EFI_DEP_REPLACE_TRUE - Used to dynamically patch the dependecy expression\r
 ///                        to save time.  A EFI_DEP_PUSH is evauated one an\r
-///                        replaced with EFI_DEP_REPLACE_TRUE\r
+///                        replaced with EFI_DEP_REPLACE_TRUE. If PI spec's Vol 2\r
+///                        Driver Execution Environment Core Interface use 0xff\r
+///                        as new DEPEX opcode. EFI_DEP_REPLACE_TRUE should be\r
+///                        defined to a new value that is not conflicting with PI spec.\r
 ///\r
 #define EFI_DEP_REPLACE_TRUE  0xff\r
 \r
@@ -127,14 +126,6 @@ typedef struct {
   BOOLEAN                     Present;\r
 } ARCHITECTURAL_PROTOCOL_ENTRY;\r
 \r
-typedef struct {\r
-  EFI_STATUS_CODE_DATA  DataHeader;\r
-  EFI_HANDLE            Handle;\r
-} EFI_DXE_DEVICE_HANDLE_EXTENDED_DATA;\r
-\r
-#define EFI_STATUS_CODE_DXE_CORE_GUID \\r
-  { 0x335984bd, 0xe805, 0x409a, { 0xb8, 0xf8, 0xd2, 0x7e, 0xce, 0x5f, 0xf7, 0xa6 } }\r
-\r
 //\r
 // DXE Dispatcher Data structures\r
 //\r
@@ -211,7 +202,6 @@ extern EFI_METRONOME_ARCH_PROTOCOL              *gMetronome;
 extern EFI_TIMER_ARCH_PROTOCOL                  *gTimer;\r
 extern EFI_SECURITY_ARCH_PROTOCOL               *gSecurity;\r
 extern EFI_BDS_ARCH_PROTOCOL                    *gBds;\r
-extern EFI_STATUS_CODE_PROTOCOL                 *gStatusCode;\r
 \r
 extern EFI_TPL                                  gEfiCurrentTpl;\r
 \r
@@ -284,12 +274,11 @@ CoreAcquireGcdMemoryLock (
 \r
 \r
 /**\r
-  External function. Initializes the GCD and memory services based on the memory\r
-  descriptor HOBs.  This function is responsible for priming the GCD map and the\r
-  memory map, so memory allocations and resource allocations can be made.  The first\r
-  part of this function can not depend on any memory services until at least one\r
-  memory descriptor is provided to the memory services.  Then the memory services\r
-  can be used to intialize the GCD map.\r
+  External function. Initializes memory services based on the memory\r
+  descriptor HOBs.  This function is responsible for priming the memory\r
+  map, so memory allocations and resource allocations can be made.\r
+  The first part of this function can not depend on any memory services\r
+  until at least one memory descriptor is provided to the memory services.\r
 \r
   @param  HobStart               The start address of the HOB.\r
   @param  MemoryBaseAddress      Start address of memory region found to init DXE\r
@@ -311,11 +300,8 @@ CoreInitializeMemoryServices (
 /**\r
   External function. Initializes the GCD and memory services based on the memory\r
   descriptor HOBs.  This function is responsible for priming the GCD map and the\r
-  memory map, so memory allocations and resource allocations can be made.  The first\r
-  part of this function can not depend on any memory services until at least one\r
-  memory descriptor is provided to the memory services.  Then the memory services\r
-  can be used to intialize the GCD map. The HobStart will be relocated to a pool\r
-  buffer.\r
+  memory map, so memory allocations and resource allocations can be made. The\r
+  HobStart will be relocated to a pool buffer.\r
 \r
   @param  HobStart               The start address of the HOB\r
   @param  MemoryBaseAddress      Start address of memory region found to init DXE\r
@@ -334,7 +320,7 @@ CoreInitializeGcdServices (
 \r
 \r
 /**\r
-  Initializes "event" support and populates parts of the System and Runtime Table.\r
+  Initializes "event" support.\r
 \r
   @retval EFI_SUCCESS            Always return success\r
 \r
@@ -1572,6 +1558,7 @@ CoreCheckEvent (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreAddMemorySpace (\r
   IN EFI_GCD_MEMORY_TYPE   GcdMemoryType,\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
@@ -1598,6 +1585,7 @@ CoreAddMemorySpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreAllocateMemorySpace (\r
   IN     EFI_GCD_ALLOCATE_TYPE  GcdAllocateType,\r
   IN     EFI_GCD_MEMORY_TYPE    GcdMemoryType,\r
@@ -1620,6 +1608,7 @@ CoreAllocateMemorySpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreFreeMemorySpace (\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
   IN UINT64                Length\r
@@ -1637,6 +1626,7 @@ CoreFreeMemorySpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreRemoveMemorySpace (\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
   IN UINT64                Length\r
@@ -1654,6 +1644,7 @@ CoreRemoveMemorySpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreGetMemorySpaceDescriptor (\r
   IN  EFI_PHYSICAL_ADDRESS             BaseAddress,\r
   OUT EFI_GCD_MEMORY_SPACE_DESCRIPTOR  *Descriptor\r
@@ -1673,6 +1664,7 @@ CoreGetMemorySpaceDescriptor (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreSetMemorySpaceAttributes (\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
   IN UINT64                Length,\r
@@ -1693,6 +1685,7 @@ CoreSetMemorySpaceAttributes (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreGetMemorySpaceMap (\r
   OUT UINTN                            *NumberOfDescriptors,\r
   OUT EFI_GCD_MEMORY_SPACE_DESCRIPTOR  **MemorySpaceMap\r
@@ -1711,6 +1704,7 @@ CoreGetMemorySpaceMap (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreAddIoSpace (\r
   IN EFI_GCD_IO_TYPE       GcdIoType,\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
@@ -1736,6 +1730,7 @@ CoreAddIoSpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreAllocateIoSpace (\r
   IN     EFI_GCD_ALLOCATE_TYPE  GcdAllocateType,\r
   IN     EFI_GCD_IO_TYPE        GcdIoType,\r
@@ -1758,6 +1753,7 @@ CoreAllocateIoSpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreFreeIoSpace (\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
   IN UINT64                Length\r
@@ -1775,6 +1771,7 @@ CoreFreeIoSpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreRemoveIoSpace (\r
   IN EFI_PHYSICAL_ADDRESS  BaseAddress,\r
   IN UINT64                Length\r
@@ -1792,6 +1789,7 @@ CoreRemoveIoSpace (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreGetIoSpaceDescriptor (\r
   IN  EFI_PHYSICAL_ADDRESS         BaseAddress,\r
   OUT EFI_GCD_IO_SPACE_DESCRIPTOR  *Descriptor\r
@@ -1810,6 +1808,7 @@ CoreGetIoSpaceDescriptor (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreGetIoSpaceMap (\r
   OUT UINTN                        *NumberOfDescriptors,\r
   OUT EFI_GCD_IO_SPACE_DESCRIPTOR  **IoSpaceMap\r
@@ -1957,6 +1956,7 @@ InitializeSectionExtraction (
 \r
 **/\r
 EFI_STATUS\r
+EFIAPI\r
 CoreProcessFirmwareVolume (\r
   IN VOID                             *FvHeader,\r
   IN UINTN                            Size,\r
@@ -2099,24 +2099,6 @@ CoreEfiNotAvailableYetArg5 (
   );\r
 \r
 \r
-/**\r
-  Searches for a Protocol Interface passed from PEI through a HOB.\r
-\r
-  @param  ProtocolGuid           The Protocol GUID to search for in the HOB List\r
-  @param  Interface              A pointer to the interface for the Protocol GUID\r
-\r
-  @retval EFI_SUCCESS            The Protocol GUID was found and its interface is\r
-                                 returned in Interface\r
-  @retval EFI_NOT_FOUND          The Protocol GUID was not found in the HOB List\r
-\r
-**/\r
-EFI_STATUS\r
-CoreGetPeiProtocol (\r
-  IN EFI_GUID  *ProtocolGuid,\r
-  IN VOID      **Interface\r
-  );\r
-\r
-\r
 /**\r
   Given a compressed source buffer, this function retrieves the size of the\r
   uncompressed buffer and the size of the scratch buffer required to decompress\r