TianoCore EDK2 master
Loading...
Searching...
No Matches
DxeMain.h File Reference
#include <PiDxe.h>
#include <Protocol/LoadedImage.h>
#include <Protocol/GuidedSectionExtraction.h>
#include <Protocol/DevicePath.h>
#include <Protocol/Runtime.h>
#include <Protocol/LoadFile.h>
#include <Protocol/LoadFile2.h>
#include <Protocol/DriverBinding.h>
#include <Protocol/VariableWrite.h>
#include <Protocol/PlatformDriverOverride.h>
#include <Protocol/Variable.h>
#include <Protocol/Timer.h>
#include <Protocol/SimpleFileSystem.h>
#include <Protocol/Bds.h>
#include <Protocol/RealTimeClock.h>
#include <Protocol/WatchdogTimer.h>
#include <Protocol/FirmwareVolume2.h>
#include <Protocol/MonotonicCounter.h>
#include <Protocol/StatusCode.h>
#include <Protocol/Decompress.h>
#include <Protocol/LoadPe32Image.h>
#include <Protocol/Security.h>
#include <Protocol/Security2.h>
#include <Protocol/Reset.h>
#include <Protocol/Cpu.h>
#include <Protocol/Metronome.h>
#include <Protocol/FirmwareVolumeBlock.h>
#include <Protocol/Capsule.h>
#include <Protocol/BusSpecificDriverOverride.h>
#include <Protocol/DriverFamilyOverride.h>
#include <Protocol/TcgService.h>
#include <Protocol/HiiPackageList.h>
#include <Protocol/SmmBase2.h>
#include <Protocol/PeCoffImageEmulator.h>
#include <Guid/MemoryTypeInformation.h>
#include <Guid/FirmwareFileSystem2.h>
#include <Guid/FirmwareFileSystem3.h>
#include <Guid/HobList.h>
#include <Guid/DebugImageInfoTable.h>
#include <Guid/FileInfo.h>
#include <Guid/Apriori.h>
#include <Guid/DxeServices.h>
#include <Guid/MemoryAllocationHob.h>
#include <Guid/EventLegacyBios.h>
#include <Guid/EventGroup.h>
#include <Guid/EventExitBootServiceFailed.h>
#include <Guid/LoadModuleAtFixedAddress.h>
#include <Guid/IdleLoopEvent.h>
#include <Guid/VectorHandoffTable.h>
#include <Ppi/VectorHandoffInfo.h>
#include <Guid/MemoryProfile.h>
#include <Library/DxeCoreEntryPoint.h>
#include <Library/DebugLib.h>
#include <Library/UefiLib.h>
#include <Library/BaseLib.h>
#include <Library/HobLib.h>
#include <Library/PerformanceLib.h>
#include <Library/UefiDecompressLib.h>
#include <Library/ExtractGuidedSectionLib.h>
#include <Library/CacheMaintenanceLib.h>
#include <Library/BaseMemoryLib.h>
#include <Library/PeCoffLib.h>
#include <Library/PeCoffGetEntryPointLib.h>
#include <Library/PeCoffExtraActionLib.h>
#include <Library/PcdLib.h>
#include <Library/MemoryAllocationLib.h>
#include <Library/DevicePathLib.h>
#include <Library/UefiBootServicesTableLib.h>
#include <Library/ReportStatusCodeLib.h>
#include <Library/DxeServicesLib.h>
#include <Library/DebugAgentLib.h>
#include <Library/CpuExceptionHandlerLib.h>
#include <Library/OrderedCollectionLib.h>

Go to the source code of this file.

Data Structures

struct  EFI_CORE_PROTOCOL_NOTIFY_ENTRY
 
struct  KNOWN_HANDLE
 
struct  EFI_CORE_DRIVER_ENTRY
 
struct  EFI_GCD_MAP_ENTRY
 
struct  LOADED_IMAGE_PRIVATE_DATA
 

Macros

#define EFI_MEMORY_PRESENT   0x0100000000000000ULL
 
#define EFI_MEMORY_INITIALIZED   0x0200000000000000ULL
 
#define EFI_MEMORY_TESTED   0x0400000000000000ULL
 
#define EFI_MEMORY_PORT_IO   0x4000000000000000ULL
 
#define EFI_DEP_REPLACE_TRUE   0xff
 
#define DEPEX_STACK_SIZE_INCREMENT   0x1000
 
#define KNOWN_HANDLE_SIGNATURE   SIGNATURE_32('k','n','o','w')
 
#define EFI_CORE_DRIVER_ENTRY_SIGNATURE   SIGNATURE_32('d','r','v','r')
 
#define EFI_GCD_MAP_SIGNATURE   SIGNATURE_32('g','c','d','m')
 
#define LOADED_IMAGE_PRIVATE_DATA_SIGNATURE   SIGNATURE_32('l','d','r','i')
 
#define LOADED_IMAGE_PRIVATE_DATA_FROM_THIS(a)    CR(a, LOADED_IMAGE_PRIVATE_DATA, Info, LOADED_IMAGE_PRIVATE_DATA_SIGNATURE)
 

Functions

VOID CoreInitializePool (VOID)
 
VOID CoreSetMemoryTypeInformationRange (IN EFI_PHYSICAL_ADDRESS Start, IN UINT64 Length)
 
VOID CoreAddMemoryDescriptor (IN EFI_MEMORY_TYPE Type, IN EFI_PHYSICAL_ADDRESS Start, IN UINT64 NumberOfPages, IN UINT64 Attribute)
 
VOID CoreReleaseGcdMemoryLock (VOID)
 
VOID CoreAcquireGcdMemoryLock (VOID)
 
EFI_STATUS CoreInitializeMemoryServices (IN VOID **HobStart, OUT EFI_PHYSICAL_ADDRESS *MemoryBaseAddress, OUT UINT64 *MemoryLength)
 
EFI_STATUS CoreInitializeGcdServices (IN OUT VOID **HobStart, IN EFI_PHYSICAL_ADDRESS MemoryBaseAddress, IN UINT64 MemoryLength)
 
EFI_STATUS CoreInitializeEventServices (VOID)
 
EFI_STATUS CoreInitializeImageServices (IN VOID *HobStart)
 
VOID CoreNotifyOnProtocolInstallation (VOID)
 
EFI_STATUS CoreAllEfiServicesAvailable (VOID)
 
VOID CalculateEfiHdrCrc (IN OUT EFI_TABLE_HEADER *Hdr)
 
VOID EFIAPI CoreTimerTick (IN UINT64 Duration)
 
VOID CoreInitializeDispatcher (VOID)
 
BOOLEAN CoreIsSchedulable (IN EFI_CORE_DRIVER_ENTRY *DriverEntry)
 
EFI_STATUS CorePreProcessDepex (IN EFI_CORE_DRIVER_ENTRY *DriverEntry)
 
EFI_STATUS EFIAPI CoreExitBootServices (IN EFI_HANDLE ImageHandle, IN UINTN MapKey)
 
EFI_STATUS CoreTerminateMemoryMap (IN UINTN MapKey)
 
VOID CoreNotifySignalList (IN EFI_GUID *EventGroup)
 
EFI_STATUS EFIAPI CoreInstallConfigurationTable (IN EFI_GUID *Guid, IN VOID *Table)
 
EFI_TPL EFIAPI CoreRaiseTpl (IN EFI_TPL NewTpl)
 
VOID EFIAPI CoreRestoreTpl (IN EFI_TPL NewTpl)
 
EFI_STATUS EFIAPI CoreStall (IN UINTN Microseconds)
 
EFI_STATUS EFIAPI CoreSetWatchdogTimer (IN UINTN Timeout, IN UINT64 WatchdogCode, IN UINTN DataSize, IN CHAR16 *WatchdogData OPTIONAL)
 
EFI_STATUS EFIAPI CoreInstallProtocolInterface (IN OUT EFI_HANDLE *UserHandle, IN EFI_GUID *Protocol, IN EFI_INTERFACE_TYPE InterfaceType, IN VOID *Interface)
 
EFI_STATUS CoreInstallProtocolInterfaceNotify (IN OUT EFI_HANDLE *UserHandle, IN EFI_GUID *Protocol, IN EFI_INTERFACE_TYPE InterfaceType, IN VOID *Interface, IN BOOLEAN Notify)
 
EFI_STATUS EFIAPI CoreInstallMultipleProtocolInterfaces (IN OUT EFI_HANDLE *Handle,...)
 
EFI_STATUS EFIAPI CoreUninstallMultipleProtocolInterfaces (IN EFI_HANDLE Handle,...)
 
EFI_STATUS EFIAPI CoreReinstallProtocolInterface (IN EFI_HANDLE UserHandle, IN EFI_GUID *Protocol, IN VOID *OldInterface, IN VOID *NewInterface)
 
EFI_STATUS EFIAPI CoreUninstallProtocolInterface (IN EFI_HANDLE UserHandle, IN EFI_GUID *Protocol, IN VOID *Interface)
 
EFI_STATUS EFIAPI CoreHandleProtocol (IN EFI_HANDLE UserHandle, IN EFI_GUID *Protocol, OUT VOID **Interface)
 
EFI_STATUS EFIAPI CoreOpenProtocol (IN EFI_HANDLE UserHandle, IN EFI_GUID *Protocol, OUT VOID **Interface OPTIONAL, IN EFI_HANDLE ImageHandle, IN EFI_HANDLE ControllerHandle, IN UINT32 Attributes)
 
EFI_STATUS EFIAPI CoreOpenProtocolInformation (IN EFI_HANDLE UserHandle, IN EFI_GUID *Protocol, OUT EFI_OPEN_PROTOCOL_INFORMATION_ENTRY **EntryBuffer, OUT UINTN *EntryCount)
 
EFI_STATUS EFIAPI CoreCloseProtocol (IN EFI_HANDLE UserHandle, IN EFI_GUID *Protocol, IN EFI_HANDLE AgentHandle, IN EFI_HANDLE ControllerHandle)
 
EFI_STATUS EFIAPI CoreProtocolsPerHandle (IN EFI_HANDLE UserHandle, OUT EFI_GUID ***ProtocolBuffer, OUT UINTN *ProtocolBufferCount)
 
EFI_STATUS EFIAPI CoreRegisterProtocolNotify (IN EFI_GUID *Protocol, IN EFI_EVENT Event, OUT VOID **Registration)
 
EFI_STATUS CoreUnregisterProtocolNotify (IN EFI_EVENT Event)
 
EFI_STATUS EFIAPI CoreLocateHandle (IN EFI_LOCATE_SEARCH_TYPE SearchType, IN EFI_GUID *Protocol OPTIONAL, IN VOID *SearchKey OPTIONAL, IN OUT UINTN *BufferSize, OUT EFI_HANDLE *Buffer)
 
EFI_STATUS EFIAPI CoreLocateDevicePath (IN EFI_GUID *Protocol, IN OUT EFI_DEVICE_PATH_PROTOCOL **DevicePath, OUT EFI_HANDLE *Device)
 
EFI_STATUS EFIAPI CoreLocateHandleBuffer (IN EFI_LOCATE_SEARCH_TYPE SearchType, IN EFI_GUID *Protocol OPTIONAL, IN VOID *SearchKey OPTIONAL, IN OUT UINTN *NumberHandles, OUT EFI_HANDLE **Buffer)
 
EFI_STATUS EFIAPI CoreLocateProtocol (IN EFI_GUID *Protocol, IN VOID *Registration OPTIONAL, OUT VOID **Interface)
 
UINT64 CoreGetHandleDatabaseKey (VOID)
 
VOID CoreConnectHandlesByKey (UINT64 Key)
 
EFI_STATUS EFIAPI CoreConnectController (IN EFI_HANDLE ControllerHandle, IN EFI_HANDLE *DriverImageHandle OPTIONAL, IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath OPTIONAL, IN BOOLEAN Recursive)
 
EFI_STATUS EFIAPI CoreDisconnectController (IN EFI_HANDLE ControllerHandle, IN EFI_HANDLE DriverImageHandle OPTIONAL, IN EFI_HANDLE ChildHandle OPTIONAL)
 
EFI_STATUS EFIAPI CoreAllocatePages (IN EFI_ALLOCATE_TYPE Type, IN EFI_MEMORY_TYPE MemoryType, IN UINTN NumberOfPages, IN OUT EFI_PHYSICAL_ADDRESS *Memory)
 
EFI_STATUS EFIAPI CoreFreePages (IN EFI_PHYSICAL_ADDRESS Memory, IN UINTN NumberOfPages)
 
EFI_STATUS EFIAPI CoreGetMemoryMap (IN OUT UINTN *MemoryMapSize, IN OUT EFI_MEMORY_DESCRIPTOR *MemoryMap, OUT UINTN *MapKey, OUT UINTN *DescriptorSize, OUT UINT32 *DescriptorVersion)
 
EFI_STATUS EFIAPI CoreAllocatePool (IN EFI_MEMORY_TYPE PoolType, IN UINTN Size, OUT VOID **Buffer)
 
EFI_STATUS EFIAPI CoreInternalAllocatePool (IN EFI_MEMORY_TYPE PoolType, IN UINTN Size, OUT VOID **Buffer)
 
EFI_STATUS EFIAPI CoreFreePool (IN VOID *Buffer)
 
EFI_STATUS EFIAPI CoreInternalFreePool (IN VOID *Buffer, OUT EFI_MEMORY_TYPE *PoolType OPTIONAL)
 
EFI_STATUS EFIAPI CoreLoadImage (IN BOOLEAN BootPolicy, IN EFI_HANDLE ParentImageHandle, IN EFI_DEVICE_PATH_PROTOCOL *FilePath, IN VOID *SourceBuffer OPTIONAL, IN UINTN SourceSize, OUT EFI_HANDLE *ImageHandle)
 
EFI_STATUS EFIAPI CoreUnloadImage (IN EFI_HANDLE ImageHandle)
 
EFI_STATUS EFIAPI CoreStartImage (IN EFI_HANDLE ImageHandle, OUT UINTN *ExitDataSize, OUT CHAR16 **ExitData OPTIONAL)
 
EFI_STATUS EFIAPI CoreExit (IN EFI_HANDLE ImageHandle, IN EFI_STATUS Status, IN UINTN ExitDataSize, IN CHAR16 *ExitData OPTIONAL)
 
EFI_STATUS EFIAPI CoreCreateEvent (IN UINT32 Type, IN EFI_TPL NotifyTpl, IN EFI_EVENT_NOTIFY NotifyFunction OPTIONAL, IN VOID *NotifyContext OPTIONAL, OUT EFI_EVENT *Event)
 
EFI_STATUS EFIAPI CoreCreateEventEx (IN UINT32 Type, IN EFI_TPL NotifyTpl, IN EFI_EVENT_NOTIFY NotifyFunction OPTIONAL, IN CONST VOID *NotifyContext OPTIONAL, IN CONST EFI_GUID *EventGroup OPTIONAL, OUT EFI_EVENT *Event)
 
EFI_STATUS EFIAPI CoreCreateEventInternal (IN UINT32 Type, IN EFI_TPL NotifyTpl, IN EFI_EVENT_NOTIFY NotifyFunction OPTIONAL, IN CONST VOID *NotifyContext OPTIONAL, IN CONST EFI_GUID *EventGroup OPTIONAL, OUT EFI_EVENT *Event)
 
EFI_STATUS EFIAPI CoreSetTimer (IN EFI_EVENT UserEvent, IN EFI_TIMER_DELAY Type, IN UINT64 TriggerTime)
 
EFI_STATUS EFIAPI CoreSignalEvent (IN EFI_EVENT UserEvent)
 
EFI_STATUS EFIAPI CoreWaitForEvent (IN UINTN NumberOfEvents, IN EFI_EVENT *UserEvents, OUT UINTN *UserIndex)
 
EFI_STATUS EFIAPI CoreCloseEvent (IN EFI_EVENT UserEvent)
 
EFI_STATUS EFIAPI CoreCheckEvent (IN EFI_EVENT UserEvent)
 
EFI_STATUS EFIAPI CoreAddMemorySpace (IN EFI_GCD_MEMORY_TYPE GcdMemoryType, IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length, IN UINT64 Capabilities)
 
EFI_STATUS EFIAPI CoreAllocateMemorySpace (IN EFI_GCD_ALLOCATE_TYPE GcdAllocateType, IN EFI_GCD_MEMORY_TYPE GcdMemoryType, IN UINTN Alignment, IN UINT64 Length, IN OUT EFI_PHYSICAL_ADDRESS *BaseAddress, IN EFI_HANDLE ImageHandle, IN EFI_HANDLE DeviceHandle OPTIONAL)
 
EFI_STATUS EFIAPI CoreFreeMemorySpace (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length)
 
EFI_STATUS EFIAPI CoreRemoveMemorySpace (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length)
 
EFI_STATUS EFIAPI CoreGetMemorySpaceDescriptor (IN EFI_PHYSICAL_ADDRESS BaseAddress, OUT EFI_GCD_MEMORY_SPACE_DESCRIPTOR *Descriptor)
 
EFI_STATUS EFIAPI CoreSetMemorySpaceAttributes (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length, IN UINT64 Attributes)
 
EFI_STATUS EFIAPI CoreSetMemorySpaceCapabilities (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length, IN UINT64 Capabilities)
 
EFI_STATUS EFIAPI CoreGetMemorySpaceMap (OUT UINTN *NumberOfDescriptors, OUT EFI_GCD_MEMORY_SPACE_DESCRIPTOR **MemorySpaceMap)
 
EFI_STATUS EFIAPI CoreAddIoSpace (IN EFI_GCD_IO_TYPE GcdIoType, IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length)
 
EFI_STATUS EFIAPI CoreAllocateIoSpace (IN EFI_GCD_ALLOCATE_TYPE GcdAllocateType, IN EFI_GCD_IO_TYPE GcdIoType, IN UINTN Alignment, IN UINT64 Length, IN OUT EFI_PHYSICAL_ADDRESS *BaseAddress, IN EFI_HANDLE ImageHandle, IN EFI_HANDLE DeviceHandle OPTIONAL)
 
EFI_STATUS EFIAPI CoreFreeIoSpace (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length)
 
EFI_STATUS EFIAPI CoreRemoveIoSpace (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length)
 
EFI_STATUS EFIAPI CoreGetIoSpaceDescriptor (IN EFI_PHYSICAL_ADDRESS BaseAddress, OUT EFI_GCD_IO_SPACE_DESCRIPTOR *Descriptor)
 
EFI_STATUS EFIAPI CoreGetIoSpaceMap (OUT UINTN *NumberOfDescriptors, OUT EFI_GCD_IO_SPACE_DESCRIPTOR **IoSpaceMap)
 
EFI_STATUS EFIAPI CoreDispatcher (VOID)
 
EFI_STATUS EFIAPI CoreSchedule (IN EFI_HANDLE FirmwareVolumeHandle, IN EFI_GUID *DriverName)
 
EFI_STATUS EFIAPI CoreTrust (IN EFI_HANDLE FirmwareVolumeHandle, IN EFI_GUID *DriverName)
 
EFI_STATUS EFIAPI FwVolDriverInit (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
 
EFI_STATUS EFIAPI InitializeSectionExtraction (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
 
EFI_STATUS EFIAPI CoreProcessFirmwareVolume (IN VOID *FvHeader, IN UINTN Size, OUT EFI_HANDLE *FVProtocolHandle)
 
VOID CoreDisplayMissingArchProtocols (VOID)
 
VOID CoreDisplayDiscoveredNotDispatched (VOID)
 
EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg1 (UINTN Arg1)
 
EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg2 (UINTN Arg1, UINTN Arg2)
 
EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg3 (UINTN Arg1, UINTN Arg2, UINTN Arg3)
 
EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg4 (UINTN Arg1, UINTN Arg2, UINTN Arg3, UINTN Arg4)
 
EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg5 (UINTN Arg1, UINTN Arg2, UINTN Arg3, UINTN Arg4, UINTN Arg5)
 
EFI_STATUS EFIAPI DxeMainUefiDecompressGetInfo (IN EFI_DECOMPRESS_PROTOCOL *This, IN VOID *Source, IN UINT32 SourceSize, OUT UINT32 *DestinationSize, OUT UINT32 *ScratchSize)
 
EFI_STATUS EFIAPI DxeMainUefiDecompress (IN EFI_DECOMPRESS_PROTOCOL *This, IN VOID *Source, IN UINT32 SourceSize, IN OUT VOID *Destination, IN UINT32 DestinationSize, IN OUT VOID *Scratch, IN UINT32 ScratchSize)
 
EFI_STATUS EFIAPI OpenSectionStream (IN UINTN SectionStreamLength, IN VOID *SectionStream, OUT UINTN *SectionStreamHandle)
 
EFI_STATUS EFIAPI GetSection (IN UINTN SectionStreamHandle, IN EFI_SECTION_TYPE *SectionType, IN EFI_GUID *SectionDefinitionGuid, IN UINTN SectionInstance, IN VOID **Buffer, IN OUT UINTN *BufferSize, OUT UINT32 *AuthenticationStatus, IN BOOLEAN IsFfs3Fv)
 
EFI_STATUS EFIAPI CloseSectionStream (IN UINTN StreamHandleToClose, IN BOOLEAN FreeStreamBuffer)
 
VOID CoreInitializeDebugImageInfoTable (VOID)
 
VOID CoreUpdateDebugTableCrc32 (VOID)
 
VOID CoreNewDebugImageInfoEntry (IN UINT32 ImageInfoType, IN EFI_LOADED_IMAGE_PROTOCOL *LoadedImage, IN EFI_HANDLE ImageHandle)
 
VOID CoreRemoveDebugImageInfoEntry (EFI_HANDLE ImageHandle)
 
EFI_STATUS EFIAPI FwVolBlockDriverInit (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
 
UINT32 GetFvbAuthenticationStatus (IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *FvbProtocol)
 
EFI_STATUS ProduceFVBProtocolOnBuffer (IN EFI_PHYSICAL_ADDRESS BaseAddress, IN UINT64 Length, IN EFI_HANDLE ParentHandle, IN UINT32 AuthenticationStatus, OUT EFI_HANDLE *FvProtocol OPTIONAL)
 
VOID CoreAcquireLock (IN EFI_LOCK *Lock)
 
EFI_STATUS CoreAcquireLockOrFail (IN EFI_LOCK *Lock)
 
VOID CoreReleaseLock (IN EFI_LOCK *Lock)
 
EFI_STATUS ReadFvbData (IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *Fvb, IN OUT EFI_LBA *StartLba, IN OUT UINTN *Offset, IN UINTN DataSize, OUT UINT8 *Data)
 
EFI_STATUS GetFwVolHeader (IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL *Fvb, OUT EFI_FIRMWARE_VOLUME_HEADER **FwVolHeader)
 
BOOLEAN VerifyFvHeaderChecksum (IN EFI_FIRMWARE_VOLUME_HEADER *FvHeader)
 
VOID MemoryProfileInit (IN VOID *HobStart)
 
VOID MemoryProfileInstallProtocol (VOID)
 
EFI_STATUS RegisterMemoryProfileImage (IN LOADED_IMAGE_PRIVATE_DATA *DriverEntry, IN EFI_FV_FILETYPE FileType)
 
EFI_STATUS UnregisterMemoryProfileImage (IN LOADED_IMAGE_PRIVATE_DATA *DriverEntry)
 
EFI_STATUS EFIAPI CoreUpdateProfile (IN EFI_PHYSICAL_ADDRESS CallerAddress, IN MEMORY_PROFILE_ACTION Action, IN EFI_MEMORY_TYPE MemoryType, IN UINTN Size, IN VOID *Buffer, IN CHAR8 *ActionString OPTIONAL)
 
VOID CoreUpdateMemoryAttributes (IN EFI_PHYSICAL_ADDRESS Start, IN UINT64 NumberOfPages, IN UINT64 NewAttributes)
 
VOID EFIAPI CoreInitializeMemoryAttributesTable (VOID)
 
VOID EFIAPI CoreInitializeMemoryProtection (VOID)
 
VOID InstallMemoryAttributesTableOnMemoryAllocation (IN EFI_MEMORY_TYPE MemoryType)
 
VOID InsertImageRecord (IN EFI_RUNTIME_IMAGE_ENTRY *RuntimeImage)
 
VOID RemoveImageRecord (IN EFI_RUNTIME_IMAGE_ENTRY *RuntimeImage)
 
VOID ProtectUefiImage (IN EFI_LOADED_IMAGE_PROTOCOL *LoadedImage, IN EFI_DEVICE_PATH_PROTOCOL *LoadedImageDevicePath)
 
VOID UnprotectUefiImage (IN EFI_LOADED_IMAGE_PROTOCOL *LoadedImage, IN EFI_DEVICE_PATH_PROTOCOL *LoadedImageDevicePath)
 
VOID MemoryProtectionExitBootServicesCallback (VOID)
 
EFI_STATUS EFIAPI ApplyMemoryProtectionPolicy (IN EFI_MEMORY_TYPE OldType, IN EFI_MEMORY_TYPE NewType, IN EFI_PHYSICAL_ADDRESS Memory, IN UINT64 Length)
 
VOID MergeMemoryMap (IN OUT EFI_MEMORY_DESCRIPTOR *MemoryMap, IN OUT UINTN *MemoryMapSize, IN UINTN DescriptorSize)
 
EFI_STATUS CoreInitializeHandleServices (VOID)
 

Variables

EFI_SYSTEM_TABLEgDxeCoreST
 
EFI_RUNTIME_SERVICESgDxeCoreRT
 
EFI_DXE_SERVICESgDxeCoreDS
 
EFI_HANDLE gDxeCoreImageHandle
 
BOOLEAN gMemoryMapTerminated
 
EFI_DECOMPRESS_PROTOCOL gEfiDecompress
 
EFI_RUNTIME_ARCH_PROTOCOLgRuntime
 
EFI_CPU_ARCH_PROTOCOLgCpu
 
EFI_WATCHDOG_TIMER_ARCH_PROTOCOLgWatchdogTimer
 
EFI_METRONOME_ARCH_PROTOCOLgMetronome
 
EFI_TIMER_ARCH_PROTOCOLgTimer
 
EFI_SECURITY_ARCH_PROTOCOLgSecurity
 
EFI_SECURITY2_ARCH_PROTOCOLgSecurity2
 
EFI_BDS_ARCH_PROTOCOLgBds
 
EFI_SMM_BASE2_PROTOCOLgSmmBase2
 
EFI_TPL gEfiCurrentTpl
 
EFI_GUIDgDxeCoreFileName
 
EFI_LOADED_IMAGE_PROTOCOLgDxeCoreLoadedImage
 
EFI_MEMORY_TYPE_INFORMATION gMemoryTypeInformation [EfiMaxMemoryType+1]
 
BOOLEAN gDispatcherRunning
 
EFI_RUNTIME_ARCH_PROTOCOL gRuntimeTemplate
 
BOOLEAN gMemoryAttributesTableForwardCfi
 
EFI_LOAD_FIXED_ADDRESS_CONFIGURATION_TABLE gLoadModuleAtFixAddressConfigurationTable
 
BOOLEAN gLoadFixedAddressCodeMemoryReady
 

Detailed Description

The internal header file includes the common header files, defines internal structure and functions used by DxeCore module.

Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file DxeMain.h.

Macro Definition Documentation

◆ DEPEX_STACK_SIZE_INCREMENT

#define DEPEX_STACK_SIZE_INCREMENT   0x1000

Define the initial size of the dependency expression evaluation stack

Definition at line 114 of file DxeMain.h.

◆ EFI_CORE_DRIVER_ENTRY_SIGNATURE

#define EFI_CORE_DRIVER_ENTRY_SIGNATURE   SIGNATURE_32('d','r','v','r')

Definition at line 136 of file DxeMain.h.

◆ EFI_DEP_REPLACE_TRUE

#define EFI_DEP_REPLACE_TRUE   0xff

EFI_DEP_REPLACE_TRUE - Used to dynamically patch the dependency expression to save time. A EFI_DEP_PUSH is evaluated one an replaced with EFI_DEP_REPLACE_TRUE. If PI spec's Vol 2 Driver Execution Environment Core Interface use 0xff as new DEPEX opcode. EFI_DEP_REPLACE_TRUE should be defined to a new value that is not conflicting with PI spec.

Definition at line 109 of file DxeMain.h.

◆ EFI_GCD_MAP_SIGNATURE

#define EFI_GCD_MAP_SIGNATURE   SIGNATURE_32('g','c','d','m')

Definition at line 169 of file DxeMain.h.

◆ EFI_MEMORY_INITIALIZED

#define EFI_MEMORY_INITIALIZED   0x0200000000000000ULL

Definition at line 93 of file DxeMain.h.

◆ EFI_MEMORY_PORT_IO

#define EFI_MEMORY_PORT_IO   0x4000000000000000ULL

Definition at line 99 of file DxeMain.h.

◆ EFI_MEMORY_PRESENT

#define EFI_MEMORY_PRESENT   0x0100000000000000ULL

Definition at line 92 of file DxeMain.h.

◆ EFI_MEMORY_TESTED

#define EFI_MEMORY_TESTED   0x0400000000000000ULL

Definition at line 94 of file DxeMain.h.

◆ KNOWN_HANDLE_SIGNATURE

#define KNOWN_HANDLE_SIGNATURE   SIGNATURE_32('k','n','o','w')

Definition at line 128 of file DxeMain.h.

◆ LOADED_IMAGE_PRIVATE_DATA_FROM_THIS

#define LOADED_IMAGE_PRIVATE_DATA_FROM_THIS (   a)     CR(a, LOADED_IMAGE_PRIVATE_DATA, Info, LOADED_IMAGE_PRIVATE_DATA_SIGNATURE)

Definition at line 229 of file DxeMain.h.

◆ LOADED_IMAGE_PRIVATE_DATA_SIGNATURE

#define LOADED_IMAGE_PRIVATE_DATA_SIGNATURE   SIGNATURE_32('l','d','r','i')

Definition at line 183 of file DxeMain.h.

Function Documentation

◆ ApplyMemoryProtectionPolicy()

EFI_STATUS EFIAPI ApplyMemoryProtectionPolicy ( IN EFI_MEMORY_TYPE  OldType,
IN EFI_MEMORY_TYPE  NewType,
IN EFI_PHYSICAL_ADDRESS  Memory,
IN UINT64  Length 
)

Manage memory permission attributes on a memory range, according to the configured DXE memory protection policy.

Parameters
OldTypeThe old memory type of the range
NewTypeThe new memory type of the range
MemoryThe base address of the range
LengthThe size of the range (in bytes)
Returns
EFI_SUCCESS If the the CPU arch protocol is not installed yet
EFI_SUCCESS If no DXE memory protection policy has been configured
EFI_SUCCESS If OldType and NewType use the same permission attributes
other Return value of gCpu->SetMemoryAttributes()

Manage memory permission attributes on a memory range, according to the configured DXE memory protection policy.

Parameters
OldTypeThe old memory type of the range
NewTypeThe new memory type of the range
MemoryThe base address of the range
LengthThe size of the range (in bytes)
Returns
EFI_SUCCESS If we are executing in SMM mode. No permission attributes are updated in this case
EFI_SUCCESS If the the CPU arch protocol is not installed yet
EFI_SUCCESS If no DXE memory protection policy has been configured
EFI_SUCCESS If OldType and NewType use the same permission attributes
other Return value of gCpu->SetMemoryAttributes()

Definition at line 1035 of file MemoryProtection.c.

◆ CalculateEfiHdrCrc()

VOID CalculateEfiHdrCrc ( IN OUT EFI_TABLE_HEADER Hdr)

Calcualte the 32-bit CRC in a EFI table using the service provided by the gRuntime service.

Parameters
HdrPointer to an EFI standard header

Calculate the 32-bit CRC in a EFI table using the service provided by the gRuntime service.

Parameters
HdrPointer to an EFI standard header

Definition at line 741 of file DxeMain.c.

◆ CloseSectionStream()

EFI_STATUS EFIAPI CloseSectionStream ( IN UINTN  StreamHandleToClose,
IN BOOLEAN  FreeStreamBuffer 
)

SEP member function. Deletes an existing section stream

Parameters
StreamHandleToCloseIndicates the stream to close
FreeStreamBufferTRUE - Need to free stream buffer; FALSE - No need to free stream buffer.
Return values
EFI_SUCCESSThe section stream is closed sucessfully.
EFI_OUT_OF_RESOURCESMemory allocation failed.
EFI_INVALID_PARAMETERSection stream does not end concident with end of last section.

Definition at line 1417 of file CoreSectionExtraction.c.

◆ CoreAcquireGcdMemoryLock()

VOID CoreAcquireGcdMemoryLock ( VOID  )

Acquire memory lock on mGcdMemorySpaceLock.

Definition at line 266 of file Gcd.c.

◆ CoreAcquireLock()

VOID CoreAcquireLock ( IN EFI_LOCK Lock)

Raising to the task priority level of the mutual exclusion lock, and then acquires ownership of the lock.

Parameters
LockThe lock to acquire
Returns
Lock owned

Definition at line 59 of file Library.c.

◆ CoreAcquireLockOrFail()

EFI_STATUS CoreAcquireLockOrFail ( IN EFI_LOCK Lock)

Initialize a basic mutual exclusion lock. Each lock provides mutual exclusion access at it's task priority level. Since there is no-premption (at any TPL) or multiprocessor support, acquiring the lock only consists of raising to the locks TPL.

Parameters
LockThe EFI_LOCK structure to initialize
Return values
EFI_SUCCESSLock Owned.
EFI_ACCESS_DENIEDReentrant Lock Acquisition, Lock not Owned.

Definition at line 29 of file Library.c.

◆ CoreAddIoSpace()

EFI_STATUS EFIAPI CoreAddIoSpace ( IN EFI_GCD_IO_TYPE  GcdIoType,
IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length 
)

Adds reserved I/O or I/O resources to the global coherency domain of the processor.

Parameters
GcdIoTypeIO type of the segment.
BaseAddressBase address of the segment.
LengthLength of the segment.
Return values
EFI_SUCCESSMerged this segment into GCD map.
EFI_INVALID_PARAMETERParameter not valid

Definition at line 1846 of file Gcd.c.

◆ CoreAddMemoryDescriptor()

VOID CoreAddMemoryDescriptor ( IN EFI_MEMORY_TYPE  Type,
IN EFI_PHYSICAL_ADDRESS  Start,
IN UINT64  NumberOfPages,
IN UINT64  Attribute 
)

Called to initialize the memory map and add descriptors to the current descriptor list. The first descriptor that is added must be general usable memory as the addition allocates heap.

Parameters
TypeThe type of memory to add
StartThe starting address in the memory range Must be page aligned
NumberOfPagesThe number of pages in the range
AttributeAttributes of the memory to add
Returns
None. The range is added to the memory map

Definition at line 653 of file Page.c.

◆ CoreAddMemorySpace()

EFI_STATUS EFIAPI CoreAddMemorySpace ( IN EFI_GCD_MEMORY_TYPE  GcdMemoryType,
IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length,
IN UINT64  Capabilities 
)

Adds reserved memory, system memory, or memory-mapped I/O resources to the global coherency domain of the processor.

Parameters
GcdMemoryTypeMemory type of the memory space.
BaseAddressBase address of the memory space.
LengthLength of the memory space.
Capabilitiesalterable attributes of the memory space.
Return values
EFI_SUCCESSMerged this memory space into GCD map.

Definition at line 1478 of file Gcd.c.

◆ CoreAllEfiServicesAvailable()

EFI_STATUS CoreAllEfiServicesAvailable ( VOID  )

Return TRUE if all AP services are available.

Return values
EFI_SUCCESSAll AP services are available
EFI_NOT_FOUNDAt least one AP service is not available

Definition at line 80 of file DxeProtocolNotify.c.

◆ CoreAllocateIoSpace()

EFI_STATUS EFIAPI CoreAllocateIoSpace ( IN EFI_GCD_ALLOCATE_TYPE  GcdAllocateType,
IN EFI_GCD_IO_TYPE  GcdIoType,
IN UINTN  Alignment,
IN UINT64  Length,
IN OUT EFI_PHYSICAL_ADDRESS BaseAddress,
IN EFI_HANDLE  ImageHandle,
IN EFI_HANDLE DeviceHandle  OPTIONAL 
)

Allocates nonexistent I/O, reserved I/O, or I/O resources from the global coherency domain of the processor.

Parameters
GcdAllocateTypeThe type of allocate operation
GcdIoTypeThe desired IO type
AlignmentAlign with 2^Alignment
LengthLength to allocate
BaseAddressBase address to allocate
ImageHandleThe image handle consume the allocated space.
DeviceHandleThe device handle consume the allocated space.
Return values
EFI_INVALID_PARAMETERInvalid parameter.
EFI_NOT_FOUNDNo descriptor contains the desired space.
EFI_SUCCESSIO space successfully allocated.

Definition at line 1884 of file Gcd.c.

◆ CoreAllocateMemorySpace()

EFI_STATUS EFIAPI CoreAllocateMemorySpace ( IN EFI_GCD_ALLOCATE_TYPE  GcdAllocateType,
IN EFI_GCD_MEMORY_TYPE  GcdMemoryType,
IN UINTN  Alignment,
IN UINT64  Length,
IN OUT EFI_PHYSICAL_ADDRESS BaseAddress,
IN EFI_HANDLE  ImageHandle,
IN EFI_HANDLE DeviceHandle  OPTIONAL 
)

Allocates nonexistent memory, reserved memory, system memory, or memorymapped I/O resources from the global coherency domain of the processor.

Parameters
GcdAllocateTypeThe type of allocate operation
GcdMemoryTypeThe desired memory type
AlignmentAlign with 2^Alignment
LengthLength to allocate
BaseAddressBase address to allocate
ImageHandleThe image handle consume the allocated space.
DeviceHandleThe device handle consume the allocated space.
Return values
EFI_INVALID_PARAMETERInvalid parameter.
EFI_NOT_FOUNDNo descriptor contains the desired space.
EFI_SUCCESSMemory space successfully allocated.

Definition at line 1429 of file Gcd.c.

◆ CoreAllocatePages()

EFI_STATUS EFIAPI CoreAllocatePages ( IN EFI_ALLOCATE_TYPE  Type,
IN EFI_MEMORY_TYPE  MemoryType,
IN UINTN  NumberOfPages,
IN OUT EFI_PHYSICAL_ADDRESS Memory 
)

Allocates pages from the memory map.

Parameters
TypeThe type of allocation to perform
MemoryTypeThe type of memory to turn the allocated pages into
NumberOfPagesThe number of pages to allocate
MemoryA pointer to receive the base allocated memory address
Returns
Status. On success, Memory is filled in with the base address allocated
Return values
EFI_INVALID_PARAMETERParameters violate checking rules defined in spec.
EFI_NOT_FOUNDCould not allocate pages match the requirement.
EFI_OUT_OF_RESOURCESNo enough pages to allocate.
EFI_SUCCESSPages successfully allocated.

◆ CoreAllocatePool()

EFI_STATUS EFIAPI CoreAllocatePool ( IN EFI_MEMORY_TYPE  PoolType,
IN UINTN  Size,
OUT VOID **  Buffer 
)

Allocate pool of a particular type.

Parameters
PoolTypeType of pool to allocate
SizeThe amount of pool to allocate
BufferThe address to return a pointer to the allocated pool
Return values
EFI_INVALID_PARAMETERPoolType not valid or Buffer is NULL
EFI_OUT_OF_RESOURCESSize exceeds max pool size or allocation failed.
EFI_SUCCESSPool successfully allocated.

Allocate pool of a particular type.

Parameters
PoolTypeType of pool to allocate
SizeThe amount of pool to allocate
BufferThe address to return a pointer to the allocated pool
Return values
EFI_INVALID_PARAMETERBuffer is NULL. PoolType is in the range EfiMaxMemoryType..0x6FFFFFFF. PoolType is EfiPersistentMemory.
EFI_OUT_OF_RESOURCESSize exceeds max pool size or allocation failed.
EFI_SUCCESSPool successfully allocated.

Definition at line 267 of file Pool.c.

◆ CoreCheckEvent()

EFI_STATUS EFIAPI CoreCheckEvent ( IN EFI_EVENT  UserEvent)

Check the status of an event.

Parameters
UserEventThe event to check
Return values
EFI_SUCCESSThe event is in the signaled state
EFI_NOT_READYThe event is not in the signaled state
EFI_INVALID_PARAMETEREvent is of type EVT_NOTIFY_SIGNAL

Definition at line 573 of file Event.c.

◆ CoreCloseEvent()

EFI_STATUS EFIAPI CoreCloseEvent ( IN EFI_EVENT  UserEvent)

Closes an event and frees the event structure.

Parameters
UserEventEvent to close
Return values
EFI_INVALID_PARAMETERParameters are not valid.
EFI_SUCCESSThe event has been closed

Definition at line 700 of file Event.c.

◆ CoreCloseProtocol()

EFI_STATUS EFIAPI CoreCloseProtocol ( IN EFI_HANDLE  UserHandle,
IN EFI_GUID Protocol,
IN EFI_HANDLE  AgentHandle,
IN EFI_HANDLE  ControllerHandle 
)

Closes a protocol on a handle that was opened using OpenProtocol().

Parameters
UserHandleThe handle for the protocol interface that was previously opened with OpenProtocol(), and is now being closed.
ProtocolThe published unique identifier of the protocol. It is the caller's responsibility to pass in a valid GUID.
AgentHandleThe handle of the agent that is closing the protocol interface.
ControllerHandleIf the agent that opened a protocol is a driver that follows the EFI Driver Model, then this parameter is the controller handle that required the protocol interface. If the agent does not follow the EFI Driver Model, then this parameter is optional and may be NULL.
Return values
EFI_SUCCESSThe protocol instance was closed.
EFI_INVALID_PARAMETERHandle, AgentHandle or ControllerHandle is not a valid EFI_HANDLE.
EFI_NOT_FOUNDCan not find the specified protocol or AgentHandle.

Definition at line 1345 of file Handle.c.

◆ CoreConnectController()

EFI_STATUS EFIAPI CoreConnectController ( IN EFI_HANDLE  ControllerHandle,
IN EFI_HANDLE *DriverImageHandle  OPTIONAL,
IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath  OPTIONAL,
IN BOOLEAN  Recursive 
)

Connects one or more drivers to a controller.

Parameters
ControllerHandleThe handle of the controller to which driver(s) are to be connected.
DriverImageHandleA pointer to an ordered list handles that support the EFI_DRIVER_BINDING_PROTOCOL.
RemainingDevicePathA pointer to the device path that specifies a child of the controller specified by ControllerHandle.
RecursiveIf TRUE, then ConnectController() is called recursively until the entire tree of controllers below the controller specified by ControllerHandle have been created. If FALSE, then the tree of controllers is only expanded one level.
Return values
EFI_SUCCESS1) One or more drivers were connected to ControllerHandle. 2) No drivers were connected to ControllerHandle, but RemainingDevicePath is not NULL, and it is an End Device Path Node.
EFI_INVALID_PARAMETERControllerHandle is NULL.
EFI_NOT_FOUND1) There are no EFI_DRIVER_BINDING_PROTOCOL instances present in the system. 2) No drivers were connected to ControllerHandle.
EFI_SECURITY_VIOLATIONThe user has no permission to start UEFI device drivers on the device path associated with the ControllerHandle or specified by the RemainingDevicePath.

Definition at line 44 of file DriverSupport.c.

◆ CoreConnectHandlesByKey()

VOID CoreConnectHandlesByKey ( UINT64  Key)

Go connect any handles that were created or modified while a image executed.

Parameters
KeyThe Key to show that the handle has been created/modified

Definition at line 1643 of file Handle.c.

◆ CoreCreateEvent()

EFI_STATUS EFIAPI CoreCreateEvent ( IN UINT32  Type,
IN EFI_TPL  NotifyTpl,
IN EFI_EVENT_NOTIFY NotifyFunction  OPTIONAL,
IN VOID *NotifyContext  OPTIONAL,
OUT EFI_EVENT Event 
)

Creates an event.

Parameters
TypeThe type of event to create and its mode and attributes
NotifyTplThe task priority level of event notifications
NotifyFunctionPointer to the events notification function
NotifyContextPointer to the notification functions context; corresponds to parameter "Context" in the notification function
EventPointer to the newly created event if the call succeeds; undefined otherwise
Return values
EFI_SUCCESSThe event structure was created
EFI_INVALID_PARAMETEROne of the parameters has an invalid value
EFI_OUT_OF_RESOURCESThe event could not be allocated

Definition at line 279 of file Event.c.

◆ CoreCreateEventEx()

EFI_STATUS EFIAPI CoreCreateEventEx ( IN UINT32  Type,
IN EFI_TPL  NotifyTpl,
IN EFI_EVENT_NOTIFY NotifyFunction  OPTIONAL,
IN CONST VOID *NotifyContext  OPTIONAL,
IN CONST EFI_GUID *EventGroup  OPTIONAL,
OUT EFI_EVENT Event 
)

Creates an event in a group.

Parameters
TypeThe type of event to create and its mode and attributes
NotifyTplThe task priority level of event notifications
NotifyFunctionPointer to the events notification function
NotifyContextPointer to the notification functions context; corresponds to parameter "Context" in the notification function
EventGroupGUID for EventGroup if NULL act the same as gBS->CreateEvent().
EventPointer to the newly created event if the call succeeds; undefined otherwise
Return values
EFI_SUCCESSThe event structure was created
EFI_INVALID_PARAMETEROne of the parameters has an invalid value
EFI_OUT_OF_RESOURCESThe event could not be allocated

Definition at line 312 of file Event.c.

◆ CoreCreateEventInternal()

EFI_STATUS EFIAPI CoreCreateEventInternal ( IN UINT32  Type,
IN EFI_TPL  NotifyTpl,
IN EFI_EVENT_NOTIFY NotifyFunction  OPTIONAL,
IN CONST VOID *NotifyContext  OPTIONAL,
IN CONST EFI_GUID *EventGroup  OPTIONAL,
OUT EFI_EVENT Event 
)

Creates a general-purpose event structure

Parameters
TypeThe type of event to create and its mode and attributes
NotifyTplThe task priority level of event notifications
NotifyFunctionPointer to the events notification function
NotifyContextPointer to the notification functions context; corresponds to parameter "Context" in the notification function
EventGroupGUID for EventGroup if NULL act the same as gBS->CreateEvent().
EventPointer to the newly created event if the call succeeds; undefined otherwise
Return values
EFI_SUCCESSThe event structure was created
EFI_INVALID_PARAMETEROne of the parameters has an invalid value
EFI_OUT_OF_RESOURCESThe event could not be allocated

Definition at line 358 of file Event.c.

◆ CoreDisconnectController()

EFI_STATUS EFIAPI CoreDisconnectController ( IN EFI_HANDLE  ControllerHandle,
IN EFI_HANDLE DriverImageHandle  OPTIONAL,
IN EFI_HANDLE ChildHandle  OPTIONAL 
)

Disonnects a controller from a driver

Parameters
ControllerHandleControllerHandle The handle of the controller from which driver(s) are to be disconnected.
DriverImageHandleDriverImageHandle The driver to disconnect from ControllerHandle.
ChildHandleChildHandle The handle of the child to destroy.
Return values
EFI_SUCCESSOne or more drivers were disconnected from the controller.
EFI_SUCCESSOn entry, no drivers are managing ControllerHandle.
EFI_SUCCESSDriverImageHandle is not NULL, and on entry DriverImageHandle is not managing ControllerHandle.
EFI_INVALID_PARAMETERControllerHandle is NULL.
EFI_INVALID_PARAMETERDriverImageHandle is not NULL, and it is not a valid EFI_HANDLE.
EFI_INVALID_PARAMETERChildHandle is not NULL, and it is not a valid EFI_HANDLE.
EFI_OUT_OF_RESOURCESThere are not enough resources available to disconnect any drivers from ControllerHandle.
EFI_DEVICE_ERRORThe controller could not be disconnected because of a device error.

Definition at line 737 of file DriverSupport.c.

◆ CoreDispatcher()

EFI_STATUS EFIAPI CoreDispatcher ( VOID  )

This is the main Dispatcher for DXE and it exits when there are no more drivers to run. Drain the mScheduledQueue and load and start a PE image for each driver. Search the mDiscoveredList to see if any driver can be placed on the mScheduledQueue. If no drivers are placed on the mScheduledQueue exit the function. On exit it is assumed the Bds() will be called, and when the Bds() exits the Dispatcher will be called again.

Return values
EFI_ALREADY_STARTEDThe DXE Dispatcher is already running
EFI_NOT_FOUNDNo DXE Drivers were dispatched
EFI_SUCCESSOne or more DXE Drivers were dispatched

Definition at line 400 of file Dispatcher.c.

◆ CoreDisplayDiscoveredNotDispatched()

VOID CoreDisplayDiscoveredNotDispatched ( VOID  )

Traverse the discovered list for any drivers that were discovered but not loaded because the dependency experessions evaluated to false.

Definition at line 1471 of file Dispatcher.c.

◆ CoreDisplayMissingArchProtocols()

VOID CoreDisplayMissingArchProtocols ( VOID  )

Displays Architectural protocols that were not loaded and are required for DXE core to function. Only used in Debug Builds.

Definition at line 262 of file DxeProtocolNotify.c.

◆ CoreEfiNotAvailableYetArg1()

EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg1 ( UINTN  Arg1)

Place holder function until all the Boot Services and Runtime Services are available.

Parameters
Arg1Undefined
Returns
EFI_NOT_AVAILABLE_YET

Definition at line 608 of file DxeMain.c.

◆ CoreEfiNotAvailableYetArg2()

EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg2 ( UINTN  Arg1,
UINTN  Arg2 
)

Place holder function until all the Boot Services and Runtime Services are available.

Parameters
Arg1Undefined
Arg2Undefined
Returns
EFI_NOT_AVAILABLE_YET

Definition at line 632 of file DxeMain.c.

◆ CoreEfiNotAvailableYetArg3()

EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg3 ( UINTN  Arg1,
UINTN  Arg2,
UINTN  Arg3 
)

Place holder function until all the Boot Services and Runtime Services are available.

Parameters
Arg1Undefined
Arg2Undefined
Arg3Undefined
Returns
EFI_NOT_AVAILABLE_YET

Definition at line 658 of file DxeMain.c.

◆ CoreEfiNotAvailableYetArg4()

EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg4 ( UINTN  Arg1,
UINTN  Arg2,
UINTN  Arg3,
UINTN  Arg4 
)

Place holder function until all the Boot Services and Runtime Services are available.

Parameters
Arg1Undefined
Arg2Undefined
Arg3Undefined
Arg4Undefined
Returns
EFI_NOT_AVAILABLE_YET

Definition at line 686 of file DxeMain.c.

◆ CoreEfiNotAvailableYetArg5()

EFI_STATUS EFIAPI CoreEfiNotAvailableYetArg5 ( UINTN  Arg1,
UINTN  Arg2,
UINTN  Arg3,
UINTN  Arg4,
UINTN  Arg5 
)

Place holder function until all the Boot Services and Runtime Services are available.

Parameters
Arg1Undefined
Arg2Undefined
Arg3Undefined
Arg4Undefined
Arg5Undefined
Returns
EFI_NOT_AVAILABLE_YET

Definition at line 716 of file DxeMain.c.

◆ CoreExit()

EFI_STATUS EFIAPI CoreExit ( IN EFI_HANDLE  ImageHandle,
IN EFI_STATUS  Status,
IN UINTN  ExitDataSize,
IN CHAR16 *ExitData  OPTIONAL 
)

Terminates the currently loaded EFI image and returns control to boot services.

Parameters
ImageHandleHandle that identifies the image. This parameter is passed to the image on entry.
StatusThe image's exit code.
ExitDataSizeThe size, in bytes, of ExitData. Ignored if ExitStatus is EFI_SUCCESS.
ExitDataPointer to a data buffer that includes a Null-terminated Unicode string, optionally followed by additional binary data. The string is a description that the caller may use to further indicate the reason for the image's exit.
Return values
EFI_INVALID_PARAMETERImage handle is NULL or it is not current image.
EFI_SUCCESSSuccessfully terminates the currently loaded EFI image.
EFI_ACCESS_DENIEDShould never reach there.
EFI_OUT_OF_RESOURCESCould not allocate pool

Definition at line 1830 of file Image.c.

◆ CoreExitBootServices()

EFI_STATUS EFIAPI CoreExitBootServices ( IN EFI_HANDLE  ImageHandle,
IN UINTN  MapKey 
)

Terminates all boot services.

Parameters
ImageHandleHandle that identifies the exiting image.
MapKeyKey to the latest memory map.
Return values
EFI_SUCCESSBoot Services terminated
EFI_INVALID_PARAMETERMapKey is incorrect.

Definition at line 770 of file DxeMain.c.

◆ CoreFreeIoSpace()

EFI_STATUS EFIAPI CoreFreeIoSpace ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length 
)

Frees nonexistent I/O, reserved I/O, or I/O resources from the global coherency domain of the processor.

Parameters
BaseAddressBase address of the segment.
LengthLength of the segment.
Return values
EFI_SUCCESSSpace successfully freed.

Definition at line 1931 of file Gcd.c.

◆ CoreFreeMemorySpace()

EFI_STATUS EFIAPI CoreFreeMemorySpace ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length 
)

Frees nonexistent memory, reserved memory, system memory, or memory-mapped I/O resources from the global coherency domain of the processor.

Parameters
BaseAddressBase address of the memory space.
LengthLength of the memory space.
Return values
EFI_SUCCESSSpace successfully freed.

Definition at line 1551 of file Gcd.c.

◆ CoreFreePages()

EFI_STATUS EFIAPI CoreFreePages ( IN EFI_PHYSICAL_ADDRESS  Memory,
IN UINTN  NumberOfPages 
)

Frees previous allocated pages.

Parameters
MemoryBase address of memory being freed
NumberOfPagesThe number of pages to free
Return values
EFI_NOT_FOUNDCould not find the entry that covers the range
EFI_INVALID_PARAMETERAddress not aligned
Returns
EFI_SUCCESS -Pages successfully freed.

Definition at line 1737 of file Page.c.

◆ CoreFreePool()

EFI_STATUS EFIAPI CoreFreePool ( IN VOID *  Buffer)

Frees pool.

Parameters
BufferThe allocated pool entry to free
Return values
EFI_INVALID_PARAMETERBuffer is not a valid value.
EFI_SUCCESSPool successfully freed.

Definition at line 591 of file Pool.c.

◆ CoreGetHandleDatabaseKey()

UINT64 CoreGetHandleDatabaseKey ( VOID  )

return handle database key.

Returns
Handle database key.

Definition at line 1628 of file Handle.c.

◆ CoreGetIoSpaceDescriptor()

EFI_STATUS EFIAPI CoreGetIoSpaceDescriptor ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
OUT EFI_GCD_IO_SPACE_DESCRIPTOR Descriptor 
)

Retrieves the descriptor for an I/O region containing a specified address.

Parameters
BaseAddressSpecified start address
DescriptorSpecified length
Return values
EFI_INVALID_PARAMETERDescriptor is NULL.
EFI_SUCCESSSuccessfully get the IO space descriptor.

Definition at line 1995 of file Gcd.c.

◆ CoreGetIoSpaceMap()

EFI_STATUS EFIAPI CoreGetIoSpaceMap ( OUT UINTN NumberOfDescriptors,
OUT EFI_GCD_IO_SPACE_DESCRIPTOR **  IoSpaceMap 
)

Returns a map of the I/O resources in the global coherency domain of the processor.

Parameters
NumberOfDescriptorsNumber of descriptors.
IoSpaceMapDescriptor array
Return values
EFI_INVALID_PARAMETERInvalid parameter
EFI_OUT_OF_RESOURCESNo enough buffer to allocate
EFI_SUCCESSSuccessfully get IO space map.

Definition at line 2047 of file Gcd.c.

◆ CoreGetMemoryMap()

EFI_STATUS EFIAPI CoreGetMemoryMap ( IN OUT UINTN MemoryMapSize,
IN OUT EFI_MEMORY_DESCRIPTOR MemoryMap,
OUT UINTN MapKey,
OUT UINTN DescriptorSize,
OUT UINT32 *  DescriptorVersion 
)

This function returns a copy of the current memory map. The map is an array of memory descriptors, each of which describes a contiguous block of memory.

Parameters
MemoryMapSizeA pointer to the size, in bytes, of the MemoryMap buffer. On input, this is the size of the buffer allocated by the caller. On output, it is the size of the buffer returned by the firmware if the buffer was large enough, or the size of the buffer needed to contain the map if the buffer was too small.
MemoryMapA pointer to the buffer in which firmware places the current memory map.
MapKeyA pointer to the location in which firmware returns the key for the current memory map.
DescriptorSizeA pointer to the location in which firmware returns the size, in bytes, of an individual EFI_MEMORY_DESCRIPTOR.
DescriptorVersionA pointer to the location in which firmware returns the version number associated with the EFI_MEMORY_DESCRIPTOR.
Return values
EFI_SUCCESSThe memory map was returned in the MemoryMap buffer.
EFI_BUFFER_TOO_SMALLThe MemoryMap buffer was too small. The current buffer size needed to hold the memory map is returned in MemoryMapSize.
EFI_INVALID_PARAMETEROne of the parameters has an invalid value.

Definition at line 1881 of file Page.c.

◆ CoreGetMemorySpaceDescriptor()

EFI_STATUS EFIAPI CoreGetMemorySpaceDescriptor ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
OUT EFI_GCD_MEMORY_SPACE_DESCRIPTOR Descriptor 
)

Retrieves the descriptor for a memory region containing a specified address.

Parameters
BaseAddressSpecified start address
DescriptorSpecified length
Return values
EFI_INVALID_PARAMETERInvalid parameter
EFI_SUCCESSSuccessfully get memory space descriptor.

Definition at line 1617 of file Gcd.c.

◆ CoreGetMemorySpaceMap()

EFI_STATUS EFIAPI CoreGetMemorySpaceMap ( OUT UINTN NumberOfDescriptors,
OUT EFI_GCD_MEMORY_SPACE_DESCRIPTOR **  MemorySpaceMap 
)

Returns a map of the memory resources in the global coherency domain of the processor.

Parameters
NumberOfDescriptorsNumber of descriptors.
MemorySpaceMapDescriptor array
Return values
EFI_INVALID_PARAMETERInvalid parameter
EFI_OUT_OF_RESOURCESNo enough buffer to allocate
EFI_SUCCESSSuccessfully get memory space map.

Definition at line 1737 of file Gcd.c.

◆ CoreHandleProtocol()

EFI_STATUS EFIAPI CoreHandleProtocol ( IN EFI_HANDLE  UserHandle,
IN EFI_GUID Protocol,
OUT VOID **  Interface 
)

Queries a handle to determine if it supports a specified protocol.

Parameters
UserHandleThe handle being queried.
ProtocolThe published unique identifier of the protocol.
InterfaceSupplies the address where a pointer to the corresponding Protocol Interface is returned.
Returns
The requested protocol interface for the handle

Queries a handle to determine if it supports a specified protocol.

Parameters
UserHandleThe handle being queried.
ProtocolThe published unique identifier of the protocol.
InterfaceSupplies the address where a pointer to the corresponding Protocol Interface is returned.
Return values
EFI_SUCCESSThe interface information for the specified protocol was returned.
EFI_UNSUPPORTEDThe device does not support the specified protocol.
EFI_INVALID_PARAMETERHandle is NULL..
EFI_INVALID_PARAMETERProtocol is NULL.
EFI_INVALID_PARAMETERInterface is NULL.

Definition at line 1040 of file Handle.c.

◆ CoreInitializeDebugImageInfoTable()

VOID CoreInitializeDebugImageInfoTable ( VOID  )

Creates and initializes the DebugImageInfo Table. Also creates the configuration table and registers it into the system table.

Note: This function allocates memory, frees it, and then allocates memory at an address within the initial allocation. Since this function is called early in DXE core initialization (before drivers are dispatched), this should not be a problem.

Creates and initializes the DebugImageInfo Table. Also creates the configuration table and registers it into the system table.

Definition at line 30 of file DebugImageInfo.c.

◆ CoreInitializeDispatcher()

VOID CoreInitializeDispatcher ( VOID  )

Initialize the dispatcher. Initialize the notification function that runs when an FV2 protocol is added to the system.

Definition at line 1444 of file Dispatcher.c.

◆ CoreInitializeEventServices()

EFI_STATUS CoreInitializeEventServices ( VOID  )

Initializes "event" support.

Return values
EFI_SUCCESSAlways return success

Definition at line 120 of file Event.c.

◆ CoreInitializeGcdServices()

EFI_STATUS CoreInitializeGcdServices ( IN OUT VOID **  HobStart,
IN EFI_PHYSICAL_ADDRESS  MemoryBaseAddress,
IN UINT64  MemoryLength 
)

External function. Initializes the GCD and memory services based on the memory descriptor HOBs. This function is responsible for priming the GCD map and the memory map, so memory allocations and resource allocations can be made. The HobStart will be relocated to a pool buffer.

Parameters
HobStartThe start address of the HOB
MemoryBaseAddressStart address of memory region found to init DXE core.
MemoryLengthLength of memory region found to init DXE core.
Return values
EFI_SUCCESSGCD services successfully initialized.

Definition at line 2574 of file Gcd.c.

◆ CoreInitializeHandleServices()

EFI_STATUS CoreInitializeHandleServices ( VOID  )

Initializes "handle" support.

Returns
Status code.
  • Initializes "handle" support.
Returns
Status code.

Definition at line 89 of file Handle.c.

◆ CoreInitializeImageServices()

EFI_STATUS CoreInitializeImageServices ( IN VOID *  HobStart)

Add the Image Services to EFI Boot Services Table and install the protocol interfaces for this image.

Parameters
HobStartThe HOB to initialize
Returns
Status code.

Definition at line 184 of file Image.c.

◆ CoreInitializeMemoryAttributesTable()

VOID EFIAPI CoreInitializeMemoryAttributesTable ( VOID  )

Initialize MemoryAttrubutesTable support.

Definition at line 303 of file MemoryAttributesTable.c.

◆ CoreInitializeMemoryProtection()

VOID EFIAPI CoreInitializeMemoryProtection ( VOID  )

Initialize Memory Protection support.

Definition at line 931 of file MemoryProtection.c.

◆ CoreInitializeMemoryServices()

EFI_STATUS CoreInitializeMemoryServices ( IN VOID **  HobStart,
OUT EFI_PHYSICAL_ADDRESS MemoryBaseAddress,
OUT UINT64 *  MemoryLength 
)

External function. Initializes memory services based on the memory descriptor HOBs. This function is responsible for priming the memory map, so memory allocations and resource allocations can be made. The first part of this function can not depend on any memory services until at least one memory descriptor is provided to the memory services.

Parameters
HobStartThe start address of the HOB.
MemoryBaseAddressStart address of memory region found to init DXE core.
MemoryLengthLength of memory region found to init DXE core.
Return values
EFI_SUCCESSMemory services successfully initialized.

Definition at line 2236 of file Gcd.c.

◆ CoreInitializePool()

VOID CoreInitializePool ( VOID  )

Called to initialize the pool.

Definition at line 115 of file Pool.c.

◆ CoreInstallConfigurationTable()

EFI_STATUS EFIAPI CoreInstallConfigurationTable ( IN EFI_GUID Guid,
IN VOID *  Table 
)

Boot Service called to add, modify, or remove a system configuration table from the EFI System Table.

Parameters
GuidPointer to the GUID for the entry to add, update, or remove
TablePointer to the configuration table for the entry to add, update, or remove, may be NULL.
Returns
EFI_SUCCESS Guid, Table pair added, updated, or removed.
EFI_INVALID_PARAMETER Input GUID not valid.
EFI_NOT_FOUND Attempted to delete non-existant entry
EFI_OUT_OF_RESOURCES Not enough memory available

Boot Service called to add, modify, or remove a system configuration table from the EFI System Table.

Parameters
GuidPointer to the GUID for the entry to add, update, or remove
TablePointer to the configuration table for the entry to add, update, or remove, may be NULL.
Returns
EFI_SUCCESS Guid, Table pair added, updated, or removed.
EFI_INVALID_PARAMETER Input GUID is NULL.
EFI_NOT_FOUND Attempted to delete non-existant entry
EFI_OUT_OF_RESOURCES Not enough memory available

Definition at line 32 of file InstallConfigurationTable.c.

◆ CoreInstallMultipleProtocolInterfaces()

EFI_STATUS EFIAPI CoreInstallMultipleProtocolInterfaces ( IN OUT EFI_HANDLE Handle,
  ... 
)

Installs a list of protocol interface into the boot services environment. This function calls InstallProtocolInterface() in a loop. If any error occures all the protocols added by this function are removed. This is basically a lib function to save space.

Parameters
HandleThe handle to install the protocol handlers on, or NULL if a new handle is to be allocated
...EFI_GUID followed by protocol instance. A NULL terminates the list. The pairs are the arguments to InstallProtocolInterface(). All the protocols are added to Handle.
Return values
EFI_SUCCESSAll the protocol interface was installed.
EFI_OUT_OF_RESOURCESThere was not enough memory in pool to install all the protocols.
EFI_ALREADY_STARTEDA Device Path Protocol instance was passed in that is already present in the handle database.
EFI_INVALID_PARAMETERHandle is NULL.
EFI_INVALID_PARAMETERProtocol is already installed on the handle specified by Handle.

Installs a list of protocol interface into the boot services environment. This function calls InstallProtocolInterface() in a loop. If any error occures all the protocols added by this function are removed. This is basically a lib function to save space.

Parameters
HandleThe pointer to a handle to install the new protocol interfaces on, or a pointer to NULL if a new handle is to be allocated.
...EFI_GUID followed by protocol instance. A NULL terminates the list. The pairs are the arguments to InstallProtocolInterface(). All the protocols are added to Handle.
Return values
EFI_SUCCESSAll the protocol interface was installed.
EFI_OUT_OF_RESOURCESThere was not enough memory in pool to install all the protocols.
EFI_ALREADY_STARTEDA Device Path Protocol instance was passed in that is already present in the handle database.
EFI_INVALID_PARAMETERHandle is NULL.
EFI_INVALID_PARAMETERProtocol is already installed on the handle specified by Handle.

Definition at line 630 of file Handle.c.

◆ CoreInstallProtocolInterface()

EFI_STATUS EFIAPI CoreInstallProtocolInterface ( IN OUT EFI_HANDLE UserHandle,
IN EFI_GUID Protocol,
IN EFI_INTERFACE_TYPE  InterfaceType,
IN VOID *  Interface 
)

Wrapper function to CoreInstallProtocolInterfaceNotify. This is the public API which Calls the private one which contains a BOOLEAN parameter for notifications

Parameters
UserHandleThe handle to install the protocol handler on, or NULL if a new handle is to be allocated
ProtocolThe protocol to add to the handle
InterfaceTypeIndicates whether Interface is supplied in native form.
InterfaceThe interface for the protocol being added
Returns
Status code

Definition at line 398 of file Handle.c.

◆ CoreInstallProtocolInterfaceNotify()

EFI_STATUS CoreInstallProtocolInterfaceNotify ( IN OUT EFI_HANDLE UserHandle,
IN EFI_GUID Protocol,
IN EFI_INTERFACE_TYPE  InterfaceType,
IN VOID *  Interface,
IN BOOLEAN  Notify 
)

Installs a protocol interface into the boot services environment.

Parameters
UserHandleThe handle to install the protocol handler on, or NULL if a new handle is to be allocated
ProtocolThe protocol to add to the handle
InterfaceTypeIndicates whether Interface is supplied in native form.
InterfaceThe interface for the protocol being added
Notifyindicates whether notify the notification list for this protocol
Return values
EFI_INVALID_PARAMETERInvalid parameter
EFI_OUT_OF_RESOURCESNo enough buffer to allocate
EFI_SUCCESSProtocol interface successfully installed

Definition at line 432 of file Handle.c.

◆ CoreInternalAllocatePool()

EFI_STATUS EFIAPI CoreInternalAllocatePool ( IN EFI_MEMORY_TYPE  PoolType,
IN UINTN  Size,
OUT VOID **  Buffer 
)

Allocate pool of a particular type.

Parameters
PoolTypeType of pool to allocate
SizeThe amount of pool to allocate
BufferThe address to return a pointer to the allocated pool
Return values
EFI_INVALID_PARAMETERPoolType not valid or Buffer is NULL
EFI_OUT_OF_RESOURCESSize exceeds max pool size or allocation failed.
EFI_SUCCESSPool successfully allocated.

Allocate pool of a particular type.

Parameters
PoolTypeType of pool to allocate
SizeThe amount of pool to allocate
BufferThe address to return a pointer to the allocated pool
Return values
EFI_INVALID_PARAMETERBuffer is NULL. PoolType is in the range EfiMaxMemoryType..0x6FFFFFFF. PoolType is EfiPersistentMemory.
EFI_OUT_OF_RESOURCESSize exceeds max pool size or allocation failed.
EFI_SUCCESSPool successfully allocated.

Definition at line 203 of file Pool.c.

◆ CoreInternalFreePool()

EFI_STATUS EFIAPI CoreInternalFreePool ( IN VOID *  Buffer,
OUT EFI_MEMORY_TYPE *PoolType  OPTIONAL 
)

Frees pool.

Parameters
BufferThe allocated pool entry to free
PoolTypePointer to pool type
Return values
EFI_INVALID_PARAMETERBuffer is not a valid value.
EFI_SUCCESSPool successfully freed.

Definition at line 563 of file Pool.c.

◆ CoreIsSchedulable()

BOOLEAN CoreIsSchedulable ( IN EFI_CORE_DRIVER_ENTRY DriverEntry)

This is the POSTFIX version of the dependency evaluator. This code does not need to handle Before or After, as it is not valid to call this routine in this case. The SOR is just ignored and is a nop in the grammer. POSTFIX means all the math is done on top of the stack.

Parameters
DriverEntryDriverEntry element to update.
Return values
TRUEIf driver is ready to run.
FALSEIf driver is not ready to run or some fatal error was found.

Definition at line 197 of file Dependency.c.

◆ CoreLoadImage()

EFI_STATUS EFIAPI CoreLoadImage ( IN BOOLEAN  BootPolicy,
IN EFI_HANDLE  ParentImageHandle,
IN EFI_DEVICE_PATH_PROTOCOL FilePath,
IN VOID *SourceBuffer  OPTIONAL,
IN UINTN  SourceSize,
OUT EFI_HANDLE ImageHandle 
)

Loads an EFI image into memory and returns a handle to the image.

Parameters
BootPolicyIf TRUE, indicates that the request originates from the boot manager, and that the boot manager is attempting to load FilePath as a boot selection.
ParentImageHandleThe caller's image handle.
FilePathThe specific file path from which the image is loaded.
SourceBufferIf not NULL, a pointer to the memory location containing a copy of the image to be loaded.
SourceSizeThe size in bytes of SourceBuffer.
ImageHandlePointer to the returned image handle that is created when the image is successfully loaded.
Return values
EFI_SUCCESSThe image was loaded into memory.
EFI_NOT_FOUNDThe FilePath was not found.
EFI_INVALID_PARAMETEROne of the parameters has an invalid value.
EFI_UNSUPPORTEDThe image type is not supported, or the device path cannot be parsed to locate the proper protocol for loading the file.
EFI_OUT_OF_RESOURCESImage was not loaded due to insufficient resources.
EFI_LOAD_ERRORImage was not loaded because the image format was corrupt or not understood.
EFI_DEVICE_ERRORImage was not loaded because the device returned a read error.
EFI_ACCESS_DENIEDImage was not loaded because the platform policy prohibits the image from being loaded. NULL is returned in *ImageHandle.
EFI_SECURITY_VIOLATIONImage was loaded and an ImageHandle was created with a valid EFI_LOADED_IMAGE_PROTOCOL. However, the current platform policy specifies that the image should not be started.

Definition at line 1541 of file Image.c.

◆ CoreLocateDevicePath()

EFI_STATUS EFIAPI CoreLocateDevicePath ( IN EFI_GUID Protocol,
IN OUT EFI_DEVICE_PATH_PROTOCOL **  DevicePath,
OUT EFI_HANDLE Device 
)

Locates the handle to a device on the device path that best matches the specified protocol.

Parameters
ProtocolThe protocol to search for.
DevicePathOn input, a pointer to a pointer to the device path. On output, the device path pointer is modified to point to the remaining part of the devicepath.
DeviceA pointer to the returned device handle.
Return values
EFI_SUCCESSThe resulting handle was returned.
EFI_NOT_FOUNDNo handles matched the search.
EFI_INVALID_PARAMETEROne of the parameters has an invalid value.

Locates the handle to a device on the device path that supports the specified protocol.

Parameters
ProtocolSpecifies the protocol to search for.
DevicePathOn input, a pointer to a pointer to the device path. On output, the device path pointer is modified to point to the remaining part of the device path.
DeviceA pointer to the returned device handle.
Return values
EFI_SUCCESSThe resulting handle was returned.
EFI_NOT_FOUNDNo handles match the search.
EFI_INVALID_PARAMETERProtocol is NULL.
EFI_INVALID_PARAMETERDevicePath is NULL.
EFI_INVALID_PARAMETERA handle matched the search and Device is NULL.

Definition at line 448 of file Locate.c.

◆ CoreLocateHandle()

EFI_STATUS EFIAPI CoreLocateHandle ( IN EFI_LOCATE_SEARCH_TYPE  SearchType,
IN EFI_GUID *Protocol  OPTIONAL,
IN VOID *SearchKey  OPTIONAL,
IN OUT UINTN BufferSize,
OUT EFI_HANDLE Buffer 
)

Locates the requested handle(s) and returns them in Buffer.

Parameters
SearchTypeThe type of search to perform to locate the handles
ProtocolThe protocol to search for
SearchKeyDependant on SearchType
BufferSizeOn input the size of Buffer. On output the size of data returned.
BufferThe buffer to return the results in
Return values
EFI_BUFFER_TOO_SMALLBuffer too small, required buffer size is returned in BufferSize.
EFI_INVALID_PARAMETERInvalid parameter
EFI_SUCCESSSuccessfully found the requested handle(s) and returns them in Buffer.

Definition at line 269 of file Locate.c.

◆ CoreLocateHandleBuffer()

EFI_STATUS EFIAPI CoreLocateHandleBuffer ( IN EFI_LOCATE_SEARCH_TYPE  SearchType,
IN EFI_GUID *Protocol  OPTIONAL,
IN VOID *SearchKey  OPTIONAL,
IN OUT UINTN NumberHandles,
OUT EFI_HANDLE **  Buffer 
)

Function returns an array of handles that support the requested protocol in a buffer allocated from pool. This is a version of CoreLocateHandle() that allocates a buffer for the caller.

Parameters
SearchTypeSpecifies which handle(s) are to be returned.
ProtocolProvides the protocol to search by. This parameter is only valid for SearchType ByProtocol.
SearchKeySupplies the search key depending on the SearchType.
NumberHandlesThe number of handles returned in Buffer.
BufferA pointer to the buffer to return the requested array of handles that support Protocol.
Return values
EFI_SUCCESSThe result array of handles was returned.
EFI_NOT_FOUNDNo handles match the search.
EFI_OUT_OF_RESOURCESThere is not enough pool memory to store the matching results.
EFI_INVALID_PARAMETEROne or more parameters are not valid.

Definition at line 667 of file Locate.c.

◆ CoreLocateProtocol()

EFI_STATUS EFIAPI CoreLocateProtocol ( IN EFI_GUID Protocol,
IN VOID *Registration  OPTIONAL,
OUT VOID **  Interface 
)

Return the first Protocol Interface that matches the Protocol GUID. If Registration is passed in, return a Protocol Instance that was just add to the system. If Registration is NULL return the first Protocol Interface you find.

Parameters
ProtocolThe protocol to search for
RegistrationOptional Registration Key returned from RegisterProtocolNotify()
InterfaceReturn the Protocol interface (instance).
Return values
EFI_SUCCESSIf a valid Interface is returned
EFI_INVALID_PARAMETERInvalid parameter
EFI_NOT_FOUNDProtocol interface not found

Definition at line 575 of file Locate.c.

◆ CoreNewDebugImageInfoEntry()

VOID CoreNewDebugImageInfoEntry ( IN UINT32  ImageInfoType,
IN EFI_LOADED_IMAGE_PROTOCOL LoadedImage,
IN EFI_HANDLE  ImageHandle 
)

Adds a new DebugImageInfo structure to the DebugImageInfo Table. Re-Allocates the table if it's not large enough to accomidate another entry.

Parameters
ImageInfoTypetype of debug image information
LoadedImagepointer to the loaded image protocol for the image being loaded
ImageHandleimage handle for the image being loaded

Definition at line 162 of file DebugImageInfo.c.

◆ CoreNotifyOnProtocolInstallation()

VOID CoreNotifyOnProtocolInstallation ( VOID  )

Creates an event that is fired everytime a Protocol of a specific type is installed.

Creates an events for the Architectural Protocols and the optional protocols that are fired everytime a Protocol of a specific type is installed.

Definition at line 248 of file DxeProtocolNotify.c.

◆ CoreNotifySignalList()

VOID CoreNotifySignalList ( IN EFI_GUID EventGroup)

Signals all events in the EventGroup.

Parameters
EventGroupThe list to signal

Definition at line 238 of file Event.c.

◆ CoreOpenProtocol()

EFI_STATUS EFIAPI CoreOpenProtocol ( IN EFI_HANDLE  UserHandle,
IN EFI_GUID Protocol,
OUT VOID **Interface  OPTIONAL,
IN EFI_HANDLE  ImageHandle,
IN EFI_HANDLE  ControllerHandle,
IN UINT32  Attributes 
)

Locates the installed protocol handler for the handle, and invokes it to obtain the protocol interface. Usage information is registered in the protocol data base.

Parameters
UserHandleThe handle to obtain the protocol interface on
ProtocolThe ID of the protocol
InterfaceThe location to return the protocol interface
ImageHandleThe handle of the Image that is opening the protocol interface specified by Protocol and Interface.
ControllerHandleThe controller handle that is requiring this interface.
AttributesThe open mode of the protocol interface specified by Handle and Protocol.
Return values
EFI_INVALID_PARAMETERProtocol is NULL.
EFI_SUCCESSGet the protocol interface.

Definition at line 1078 of file Handle.c.

◆ CoreOpenProtocolInformation()

EFI_STATUS EFIAPI CoreOpenProtocolInformation ( IN EFI_HANDLE  UserHandle,
IN EFI_GUID Protocol,
OUT EFI_OPEN_PROTOCOL_INFORMATION_ENTRY **  EntryBuffer,
OUT UINTN EntryCount 
)

Return information about Opened protocols in the system

Parameters
UserHandleThe handle to close the protocol interface on
ProtocolThe ID of the protocol
EntryBufferA pointer to a buffer of open protocol information in the form of EFI_OPEN_PROTOCOL_INFORMATION_ENTRY structures.
EntryCountNumber of EntryBuffer entries

Return information about Opened protocols in the system

Parameters
UserHandleThe handle to close the protocol interface on
ProtocolThe ID of the protocol
EntryBufferA pointer to a buffer of open protocol information in the form of EFI_OPEN_PROTOCOL_INFORMATION_ENTRY structures.
EntryCountNumber of EntryBuffer entries
Return values
EFI_SUCCESSThe open protocol information was returned in EntryBuffer, and the number of entries was returned EntryCount.
EFI_NOT_FOUNDHandle does not support the protocol specified by Protocol.
EFI_OUT_OF_RESOURCESThere are not enough resources available to allocate EntryBuffer.

Definition at line 1436 of file Handle.c.

◆ CorePreProcessDepex()

EFI_STATUS CorePreProcessDepex ( IN EFI_CORE_DRIVER_ENTRY DriverEntry)

Preprocess dependency expression and update DriverEntry to reflect the state of Before, After, and SOR dependencies. If DriverEntry->Before or DriverEntry->After is set it will never be cleared. If SOR is set it will be cleared by CoreSchedule(), and then the driver can be dispatched.

Parameters
DriverEntryDriverEntry element to update .
Return values
EFI_SUCCESSIt always works.

Definition at line 157 of file Dependency.c.

◆ CoreProcessFirmwareVolume()

EFI_STATUS EFIAPI CoreProcessFirmwareVolume ( IN VOID *  FvHeader,
IN UINTN  Size,
OUT EFI_HANDLE FVProtocolHandle 
)

This DXE service routine is used to process a firmware volume. In particular, it can be called by BDS to process a single firmware volume found in a capsule.

Parameters
FvHeaderpointer to a firmware volume header
Sizethe size of the buffer pointed to by FvHeader
FVProtocolHandlethe handle on which a firmware volume protocol was produced for the firmware volume passed in.
Return values
EFI_OUT_OF_RESOURCESif an FVB could not be produced due to lack of system resources
EFI_VOLUME_CORRUPTEDif the volume was corrupted
EFI_SUCCESSa firmware volume protocol was produced for the firmware volume

This DXE service routine is used to process a firmware volume. In particular, it can be called by BDS to process a single firmware volume found in a capsule.

Caution: The caller need validate the input firmware volume to follow PI specification. DxeCore will trust the input data and process firmware volume directly.

Parameters
FvHeaderpointer to a firmware volume header
Sizethe size of the buffer pointed to by FvHeader
FVProtocolHandlethe handle on which a firmware volume protocol was produced for the firmware volume passed in.
Return values
EFI_OUT_OF_RESOURCESif an FVB could not be produced due to lack of system resources
EFI_VOLUME_CORRUPTEDif the volume was corrupted
EFI_SUCCESSa firmware volume protocol was produced for the firmware volume

Definition at line 676 of file FwVolBlock.c.

◆ CoreProtocolsPerHandle()

EFI_STATUS EFIAPI CoreProtocolsPerHandle ( IN EFI_HANDLE  UserHandle,
OUT EFI_GUID ***  ProtocolBuffer,
OUT UINTN ProtocolBufferCount 
)

Retrieves the list of protocol interface GUIDs that are installed on a handle in a buffer allocated from pool.

Parameters
UserHandleThe handle from which to retrieve the list of protocol interface GUIDs.
ProtocolBufferA pointer to the list of protocol interface GUID pointers that are installed on Handle.
ProtocolBufferCountA pointer to the number of GUID pointers present in ProtocolBuffer.
Return values
EFI_SUCCESSThe list of protocol interface GUIDs installed on Handle was returned in ProtocolBuffer. The number of protocol interface GUIDs was returned in ProtocolBufferCount.
EFI_INVALID_PARAMETERHandle is NULL.
EFI_INVALID_PARAMETERHandle is not a valid EFI_HANDLE.
EFI_INVALID_PARAMETERProtocolBuffer is NULL.
EFI_INVALID_PARAMETERProtocolBufferCount is NULL.
EFI_OUT_OF_RESOURCESThere is not enough pool memory to store the results.

Definition at line 1550 of file Handle.c.

◆ CoreRaiseTpl()

EFI_TPL EFIAPI CoreRaiseTpl ( IN EFI_TPL  NewTpl)

Raise the task priority level to the new level. High level is implemented by disabling processor interrupts.

Parameters
NewTplNew task priority level
Returns
The previous task priority level

Definition at line 57 of file Tpl.c.

◆ CoreRegisterProtocolNotify()

EFI_STATUS EFIAPI CoreRegisterProtocolNotify ( IN EFI_GUID Protocol,
IN EFI_EVENT  Event,
OUT VOID **  Registration 
)

Add a new protocol notification record for the request protocol.

Parameters
ProtocolThe requested protocol to add the notify registration
EventThe event to signal
RegistrationReturns the registration record
Return values
EFI_INVALID_PARAMETERInvalid parameter
EFI_SUCCESSSuccessfully returned the registration record that has been added

Definition at line 99 of file Notify.c.

◆ CoreReinstallProtocolInterface()

EFI_STATUS EFIAPI CoreReinstallProtocolInterface ( IN EFI_HANDLE  UserHandle,
IN EFI_GUID Protocol,
IN VOID *  OldInterface,
IN VOID *  NewInterface 
)

Reinstall a protocol interface on a device handle. The OldInterface for Protocol is replaced by the NewInterface.

Parameters
UserHandleHandle on which the interface is to be reinstalled
ProtocolThe numeric ID of the interface
OldInterfaceA pointer to the old interface
NewInterfaceA pointer to the new interface
Return values
EFI_SUCCESSThe protocol interface was installed
EFI_NOT_FOUNDThe OldInterface on the handle was not found
EFI_INVALID_PARAMETEROne of the parameters has an invalid value

Definition at line 173 of file Notify.c.

◆ CoreReleaseGcdMemoryLock()

VOID CoreReleaseGcdMemoryLock ( VOID  )

Release memory lock on mGcdMemorySpaceLock.

Definition at line 278 of file Gcd.c.

◆ CoreReleaseLock()

VOID CoreReleaseLock ( IN EFI_LOCK Lock)

Releases ownership of the mutual exclusion lock, and restores the previous task priority level.

Parameters
LockThe lock to release
Returns
Lock unowned

Definition at line 80 of file Library.c.

◆ CoreRemoveDebugImageInfoEntry()

VOID CoreRemoveDebugImageInfoEntry ( EFI_HANDLE  ImageHandle)

Removes and frees an entry from the DebugImageInfo Table.

Parameters
ImageHandleimage handle for the image being unloaded

Definition at line 253 of file DebugImageInfo.c.

◆ CoreRemoveIoSpace()

EFI_STATUS EFIAPI CoreRemoveIoSpace ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length 
)

Removes reserved I/O or I/O resources from the global coherency domain of the processor.

Parameters
BaseAddressBase address of the segment.
LengthLength of the segment.
Return values
EFI_SUCCESSSuccessfully removed a segment of IO space.

Definition at line 1953 of file Gcd.c.

◆ CoreRemoveMemorySpace()

EFI_STATUS EFIAPI CoreRemoveMemorySpace ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length 
)

Removes reserved memory, system memory, or memory-mapped I/O resources from the global coherency domain of the processor.

Parameters
BaseAddressBase address of the memory space.
LengthLength of the memory space.
Return values
EFI_SUCCESSSuccessfully remove a segment of memory space.

Definition at line 1573 of file Gcd.c.

◆ CoreRestoreTpl()

VOID EFIAPI CoreRestoreTpl ( IN EFI_TPL  NewTpl)

Lowers the task priority to the previous value. If the new priority unmasks events at a higher priority, they are dispatched.

Parameters
NewTplNew, lower, task priority

Definition at line 95 of file Tpl.c.

◆ CoreSchedule()

EFI_STATUS EFIAPI CoreSchedule ( IN EFI_HANDLE  FirmwareVolumeHandle,
IN EFI_GUID DriverName 
)

Check every driver and locate a matching one. If the driver is found, the Unrequested state flag is cleared.

Parameters
FirmwareVolumeHandleThe handle of the Firmware Volume that contains the firmware file specified by DriverName.
DriverNameThe Driver name to put in the Dependent state.
Return values
EFI_SUCCESSThe DriverName was found and it's SOR bit was cleared
EFI_NOT_FOUNDThe DriverName does not exist or it's SOR bit was not set.

Definition at line 301 of file Dispatcher.c.

◆ CoreSetMemorySpaceAttributes()

EFI_STATUS EFIAPI CoreSetMemorySpaceAttributes ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length,
IN UINT64  Attributes 
)

Modifies the attributes for a memory region in the global coherency domain of the processor.

Parameters
BaseAddressSpecified start address
LengthSpecified length
AttributesSpecified attributes
Return values
EFI_SUCCESSThe attributes were set for the memory region.
EFI_INVALID_PARAMETERLength is zero.
EFI_UNSUPPORTEDThe processor does not support one or more bytes of the memory resource range specified by BaseAddress and Length.
EFI_UNSUPPORTEDThe bit mask of attributes is not support for the memory resource range specified by BaseAddress and Length.
EFI_ACCESS_DENIEDThe attributes for the memory resource range specified by BaseAddress and Length cannot be modified.
EFI_OUT_OF_RESOURCESThere are not enough system resources to modify the attributes of the memory resource range.
EFI_NOT_AVAILABLE_YETThe attributes cannot be set because CPU architectural protocol is not available yet.

Modifies the attributes for a memory region in the global coherency domain of the processor.

Parameters
BaseAddressSpecified start address
LengthSpecified length
AttributesSpecified attributes
Return values
EFI_SUCCESSThe attributes were set for the memory region.
EFI_INVALID_PARAMETERLength is zero.
EFI_UNSUPPORTEDThe processor does not support one or more bytes of the memory resource range specified by BaseAddress and Length.
EFI_UNSUPPORTEDThe bit mask of attributes is not support for the memory resource range specified by BaseAddress and Length.
EFI_ACCESS_DEFINEDThe attributes for the memory resource range specified by BaseAddress and Length cannot be modified.
EFI_OUT_OF_RESOURCESThere are not enough system resources to modify the attributes of the memory resource range.
EFI_NOT_AVAILABLE_YETThe attributes cannot be set because CPU architectural protocol is not available yet.

Definition at line 1680 of file Gcd.c.

◆ CoreSetMemorySpaceCapabilities()

EFI_STATUS EFIAPI CoreSetMemorySpaceCapabilities ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length,
IN UINT64  Capabilities 
)

Modifies the capabilities for a memory region in the global coherency domain of the processor.

Parameters
BaseAddressThe physical address that is the start address of a memory region.
LengthThe size in bytes of the memory region.
CapabilitiesThe bit mask of capabilities that the memory region supports.
Return values
EFI_SUCCESSThe capabilities were set for the memory region.
EFI_INVALID_PARAMETERLength is zero.
EFI_UNSUPPORTEDThe capabilities specified by Capabilities do not include the memory region attributes currently in use.
EFI_ACCESS_DENIEDThe capabilities for the memory resource range specified by BaseAddress and Length cannot be modified.
EFI_OUT_OF_RESOURCESThere are not enough system resources to modify the capabilities of the memory resource range.

Definition at line 1711 of file Gcd.c.

◆ CoreSetMemoryTypeInformationRange()

VOID CoreSetMemoryTypeInformationRange ( IN EFI_PHYSICAL_ADDRESS  Start,
IN UINT64  Length 
)

Sets the preferred memory range to use for the Memory Type Information bins. This service must be called before fist call to CoreAddMemoryDescriptor().

If the location of the Memory Type Information bins has already been established or the size of the range provides is smaller than all the Memory Type Information bins, then the range provides is not used.

Parameters
StartThe start address of the Memory Type Information range.
LengthThe size, in bytes, of the Memory Type Information range.

Definition at line 547 of file Page.c.

◆ CoreSetTimer()

EFI_STATUS EFIAPI CoreSetTimer ( IN EFI_EVENT  UserEvent,
IN EFI_TIMER_DELAY  Type,
IN UINT64  TriggerTime 
)

Sets the type of timer and the trigger time for a timer event.

Parameters
UserEventThe timer event that is to be signaled at the specified time
TypeThe type of time that is specified in TriggerTime
TriggerTimeThe number of 100ns units until the timer expires
Return values
EFI_SUCCESSThe event has been set to be signaled at the requested time
EFI_INVALID_PARAMETEREvent or Type is not valid

Definition at line 236 of file Timer.c.

◆ CoreSetWatchdogTimer()

EFI_STATUS EFIAPI CoreSetWatchdogTimer ( IN UINTN  Timeout,
IN UINT64  WatchdogCode,
IN UINTN  DataSize,
IN CHAR16 *WatchdogData  OPTIONAL 
)

Sets the system's watchdog timer.

Parameters
TimeoutThe number of seconds to set the watchdog timer to. A value of zero disables the timer.
WatchdogCodeThe numeric code to log on a watchdog timer timeout event. The firmware reserves codes 0x0000 to 0xFFFF. Loaders and operating systems may use other timeout codes.
DataSizeThe size, in bytes, of WatchdogData.
WatchdogDataA data buffer that includes a Null-terminated Unicode string, optionally followed by additional binary data. The string is a description that the call may use to further indicate the reason to be logged with a watchdog event.
Returns
EFI_SUCCESS Timeout has been set
EFI_NOT_AVAILABLE_YET WatchdogTimer is not available yet
EFI_UNSUPPORTED System does not have a timer (currently not used)
EFI_DEVICE_ERROR Could not complete due to hardware error

Definition at line 37 of file SetWatchdogTimer.c.

◆ CoreSignalEvent()

EFI_STATUS EFIAPI CoreSignalEvent ( IN EFI_EVENT  UserEvent)

Signals the event. Queues the event to be notified if needed.

Parameters
UserEventThe event to signal .
Return values
EFI_INVALID_PARAMETERParameters are not valid.
EFI_SUCCESSThe event was signaled.

Definition at line 514 of file Event.c.

◆ CoreStall()

EFI_STATUS EFIAPI CoreStall ( IN UINTN  Microseconds)

Introduces a fine-grained stall.

Parameters
MicrosecondsThe number of microseconds to stall execution.
Return values
EFI_SUCCESSExecution was stalled for at least the requested amount of microseconds.
EFI_NOT_AVAILABLE_YETgMetronome is not available yet

Definition at line 49 of file Stall.c.

◆ CoreStartImage()

EFI_STATUS EFIAPI CoreStartImage ( IN EFI_HANDLE  ImageHandle,
OUT UINTN ExitDataSize,
OUT CHAR16 **ExitData  OPTIONAL 
)

Transfer control to a loaded image's entry point.

Parameters
ImageHandleHandle of image to be started.
ExitDataSizePointer of the size to ExitData
ExitDataPointer to a pointer to a data buffer that includes a Null-terminated string, optionally followed by additional binary data. The string is a description that the caller may use to further indicate the reason for the image's exit.
Return values
EFI_INVALID_PARAMETERInvalid parameter
EFI_OUT_OF_RESOURCESNo enough buffer to allocate
EFI_SECURITY_VIOLATIONThe current platform policy specifies that the image should not be started.
EFI_SUCCESSSuccessfully transfer control to the image's entry point.

Definition at line 1602 of file Image.c.

◆ CoreTerminateMemoryMap()

EFI_STATUS CoreTerminateMemoryMap ( IN UINTN  MapKey)

Make sure the memory map is following all the construction rules, it is the last time to check memory map error before exit boot services.

Parameters
MapKeyMemory map key
Return values
EFI_INVALID_PARAMETERMemory map not consistent with construction rules.
EFI_SUCCESSValid memory map.

Definition at line 2260 of file Page.c.

◆ CoreTimerTick()

VOID EFIAPI CoreTimerTick ( IN UINT64  Duration)

Called by the platform code to process a tick.

Parameters
DurationThe number of 100ns elapsed since the last call to TimerTick

Definition at line 188 of file Timer.c.

◆ CoreTrust()

EFI_STATUS EFIAPI CoreTrust ( IN EFI_HANDLE  FirmwareVolumeHandle,
IN EFI_GUID DriverName 
)

Convert a driver from the Untrused back to the Scheduled state.

Parameters
FirmwareVolumeHandleThe handle of the Firmware Volume that contains the firmware file specified by DriverName.
DriverNameThe Driver name to put in the Scheduled state
Return values
EFI_SUCCESSThe file was found in the untrusted state, and it was promoted to the trusted state.
EFI_NOT_FOUNDThe file was not found in the untrusted state.

Definition at line 351 of file Dispatcher.c.

◆ CoreUninstallMultipleProtocolInterfaces()

EFI_STATUS EFIAPI CoreUninstallMultipleProtocolInterfaces ( IN EFI_HANDLE  Handle,
  ... 
)

Uninstalls a list of protocol interface in the boot services environment. This function calls UnisatllProtocolInterface() in a loop. This is basically a lib function to save space.

Parameters
HandleThe handle to uninstall the protocol
...EFI_GUID followed by protocol instance. A NULL terminates the list. The pairs are the arguments to UninstallProtocolInterface(). All the protocols are added to Handle.
Returns
Status code

Uninstalls a list of protocol interface in the boot services environment. This function calls UninstallProtocolInterface() in a loop. This is basically a lib function to save space.

If any errors are generated while the protocol interfaces are being uninstalled, then the protocol interfaces uninstalled prior to the error will be reinstalled and EFI_INVALID_PARAMETER will be returned.

Parameters
HandleThe handle to uninstall the protocol interfaces from.
...EFI_GUID followed by protocol instance. A NULL terminates the list. The pairs are the arguments to UninstallProtocolInterface(). All the protocols are added to Handle.
Return values
EFI_SUCCESSif all protocol interfaces where uninstalled.
EFI_INVALID_PARAMETERif any protocol interface could not be uninstalled and an attempt was made to reinstall previously uninstalled protocol interfaces.

Definition at line 931 of file Handle.c.

◆ CoreUninstallProtocolInterface()

EFI_STATUS EFIAPI CoreUninstallProtocolInterface ( IN EFI_HANDLE  UserHandle,
IN EFI_GUID Protocol,
IN VOID *  Interface 
)

Uninstalls all instances of a protocol:interfacer from a handle. If the last protocol interface is remove from the handle, the handle is freed.

Parameters
UserHandleThe handle to remove the protocol handler from
ProtocolThe protocol, of protocol:interface, to remove
InterfaceThe interface, of protocol:interface, to remove
Return values
EFI_INVALID_PARAMETERProtocol is NULL.
EFI_SUCCESSProtocol interface successfully uninstalled.

Definition at line 805 of file Handle.c.

◆ CoreUnloadImage()

EFI_STATUS EFIAPI CoreUnloadImage ( IN EFI_HANDLE  ImageHandle)

Unloads an image.

Parameters
ImageHandleHandle that identifies the image to be unloaded.
Return values
EFI_SUCCESSThe image has been unloaded.
EFI_UNSUPPORTEDThe image has been started, and does not support unload.
EFI_INVALID_PARAMPETERImageHandle is not a valid image handle.

Definition at line 1919 of file Image.c.

◆ CoreUnregisterProtocolNotify()

EFI_STATUS CoreUnregisterProtocolNotify ( IN EFI_EVENT  Event)

Removes all the events in the protocol database that match Event.

Parameters
EventThe event to search for in the protocol database.
Returns
EFI_SUCCESS when done searching the entire database.

Definition at line 369 of file Handle.c.

◆ CoreUpdateDebugTableCrc32()

VOID CoreUpdateDebugTableCrc32 ( VOID  )

Update the CRC32 in the Debug Table. Since the CRC32 service is made available by the Runtime driver, we have to wait for the Runtime Driver to be installed before the CRC32 can be computed. This function is called elsewhere by the core when the runtime architectural protocol is produced.

Definition at line 142 of file DebugImageInfo.c.

◆ CoreUpdateMemoryAttributes()

VOID CoreUpdateMemoryAttributes ( IN EFI_PHYSICAL_ADDRESS  Start,
IN UINT64  NumberOfPages,
IN UINT64  NewAttributes 
)

Internal function. Converts a memory range to use new attributes.

Parameters
StartThe first address of the range Must be page aligned
NumberOfPagesThe number of pages to convert
NewAttributesThe new attributes value for the range.

Definition at line 1099 of file Page.c.

◆ CoreUpdateProfile()

EFI_STATUS EFIAPI CoreUpdateProfile ( IN PHYSICAL_ADDRESS  CallerAddress,
IN MEMORY_PROFILE_ACTION  Action,
IN EFI_MEMORY_TYPE  MemoryType,
IN UINTN  Size,
IN VOID *  Buffer,
IN CHAR8 *ActionString  OPTIONAL 
)

Update memory profile information.

Parameters
CallerAddressAddress of caller who call Allocate or Free.
ActionThis Allocate or Free action.
MemoryTypeMemory type. EfiMaxMemoryType means the MemoryType is unknown.
SizeBuffer size.
BufferBuffer address.
ActionStringString for memory profile action. Only needed for user defined allocate action.
Returns
EFI_SUCCESS Memory profile is updated.
EFI_UNSUPPORTED Memory profile is unsupported, or memory profile for the image is not required, or memory profile for the memory type is not required.
EFI_ACCESS_DENIED It is during memory profile data getting.
EFI_ABORTED Memory profile recording is not enabled.
EFI_OUT_OF_RESOURCES No enough resource to update memory profile for allocate action.
EFI_NOT_FOUND No matched allocate info found for free action.

Definition at line 1357 of file MemoryProfileRecord.c.

◆ CoreWaitForEvent()

EFI_STATUS EFIAPI CoreWaitForEvent ( IN UINTN  NumberOfEvents,
IN EFI_EVENT UserEvents,
OUT UINTN UserIndex 
)

Stops execution until an event is signaled.

Parameters
NumberOfEventsThe number of events in the UserEvents array
UserEventsAn array of EFI_EVENT
UserIndexPointer to the index of the event which satisfied the wait condition
Return values
EFI_SUCCESSThe event indicated by Index was signaled.
EFI_INVALID_PARAMETERThe event indicated by Index has a notification function or Event was not a valid type
EFI_UNSUPPORTEDThe current TPL is not TPL_APPLICATION

Definition at line 642 of file Event.c.

◆ DxeMainUefiDecompress()

EFI_STATUS EFIAPI DxeMainUefiDecompress ( IN EFI_DECOMPRESS_PROTOCOL This,
IN VOID *  Source,
IN UINT32  SourceSize,
IN OUT VOID *  Destination,
IN UINT32  DestinationSize,
IN OUT VOID *  Scratch,
IN UINT32  ScratchSize 
)

Decompresses a compressed source buffer.

The Decompress() function extracts decompressed data to its original form. This protocol is designed so that the decompression algorithm can be implemented without using any memory services. As a result, the Decompress() Function is not allowed to call AllocatePool() or AllocatePages() in its implementation. It is the caller's responsibility to allocate and free the Destination and Scratch buffers. If the compressed source data specified by Source and SourceSize is sucessfully decompressed into Destination, then EFI_SUCCESS is returned. If the compressed source data specified by Source and SourceSize is not in a valid compressed data format, then EFI_INVALID_PARAMETER is returned.

Parameters
ThisA pointer to the EFI_DECOMPRESS_PROTOCOL instance.
SourceThe source buffer containing the compressed data.
SourceSizeSourceSizeThe size of source data.
DestinationOn output, the destination buffer that contains the uncompressed data.
DestinationSizeThe size of the destination buffer. The size of the destination buffer needed is obtained from EFI_DECOMPRESS_PROTOCOL.GetInfo().
ScratchA temporary scratch buffer that is used to perform the decompression.
ScratchSizeThe size of scratch buffer. The size of the scratch buffer needed is obtained from GetInfo().
Return values
EFI_SUCCESSDecompression completed successfully, and the uncompressed buffer is returned in Destination.
EFI_INVALID_PARAMETERThe source buffer specified by Source and SourceSize is corrupted (not in a valid compressed format).

Decompresses a compressed source buffer.

The Decompress() function extracts decompressed data to its original form. This protocol is designed so that the decompression algorithm can be implemented without using any memory services. As a result, the Decompress() Function is not allowed to call AllocatePool() or AllocatePages() in its implementation. It is the caller's responsibility to allocate and free the Destination and Scratch buffers. If the compressed source data specified by Source and SourceSize is successfully decompressed into Destination, then EFI_SUCCESS is returned. If the compressed source data specified by Source and SourceSize is not in a valid compressed data format, then EFI_INVALID_PARAMETER is returned.

Parameters
ThisA pointer to the EFI_DECOMPRESS_PROTOCOL instance.
SourceThe source buffer containing the compressed data.
SourceSizeSourceSizeThe size of source data.
DestinationOn output, the destination buffer that contains the uncompressed data.
DestinationSizeThe size of the destination buffer. The size of the destination buffer needed is obtained from EFI_DECOMPRESS_PROTOCOL.GetInfo().
ScratchA temporary scratch buffer that is used to perform the decompression.
ScratchSizeThe size of scratch buffer. The size of the scratch buffer needed is obtained from GetInfo().
Return values
EFI_SUCCESSDecompression completed successfully, and the uncompressed buffer is returned in Destination.
EFI_INVALID_PARAMETERThe source buffer specified by Source and SourceSize is corrupted (not in a valid compressed format).

Definition at line 949 of file DxeMain.c.

◆ DxeMainUefiDecompressGetInfo()

EFI_STATUS EFIAPI DxeMainUefiDecompressGetInfo ( IN EFI_DECOMPRESS_PROTOCOL This,
IN VOID *  Source,
IN UINT32  SourceSize,
OUT UINT32 *  DestinationSize,
OUT UINT32 *  ScratchSize 
)

Given a compressed source buffer, this function retrieves the size of the uncompressed buffer and the size of the scratch buffer required to decompress the compressed source buffer.

The GetInfo() function retrieves the size of the uncompressed buffer and the temporary scratch buffer required to decompress the buffer specified by Source and SourceSize. If the size of the uncompressed buffer or the size of the scratch buffer cannot be determined from the compressed data specified by Source and SourceData, then EFI_INVALID_PARAMETER is returned. Otherwise, the size of the uncompressed buffer is returned in DestinationSize, the size of the scratch buffer is returned in ScratchSize, and EFI_SUCCESS is returned. The GetInfo() function does not have scratch buffer available to perform a thorough checking of the validity of the source data. It just retrieves the "Original Size" field from the beginning bytes of the source data and output it as DestinationSize. And ScratchSize is specific to the decompression implementation.

Parameters
ThisA pointer to the EFI_DECOMPRESS_PROTOCOL instance.
SourceThe source buffer containing the compressed data.
SourceSizeThe size, in bytes, of the source buffer.
DestinationSizeA pointer to the size, in bytes, of the uncompressed buffer that will be generated when the compressed buffer specified by Source and SourceSize is decompressed.
ScratchSizeA pointer to the size, in bytes, of the scratch buffer that is required to decompress the compressed buffer specified by Source and SourceSize.
Return values
EFI_SUCCESSThe size of the uncompressed data was returned in DestinationSize and the size of the scratch buffer was returned in ScratchSize.
EFI_INVALID_PARAMETERThe size of the uncompressed data or the size of the scratch buffer cannot be determined from the compressed data specified by Source and SourceSize.

Definition at line 898 of file DxeMain.c.

◆ FwVolBlockDriverInit()

EFI_STATUS EFIAPI FwVolBlockDriverInit ( IN EFI_HANDLE  ImageHandle,
IN EFI_SYSTEM_TABLE SystemTable 
)

This routine consumes FV hobs and produces instances of FW_VOL_BLOCK_PROTOCOL as appropriate.

Parameters
ImageHandleThe image handle.
SystemTableThe system table.
Return values
EFI_SUCCESSSuccessfully initialized firmware volume block driver.

Definition at line 613 of file FwVolBlock.c.

◆ FwVolDriverInit()

EFI_STATUS EFIAPI FwVolDriverInit ( IN EFI_HANDLE  ImageHandle,
IN EFI_SYSTEM_TABLE SystemTable 
)

This routine is the driver initialization entry point. It initializes the libraries, and registers two notification functions. These notification functions are responsible for building the FV stack dynamically.

Parameters
ImageHandleThe image handle.
SystemTableThe system table.
Return values
EFI_SUCCESSFunction successfully returned.

This routine is the driver initialization entry point. It registers a notification function. This notification function are responsible for building the FV stack dynamically.

Parameters
ImageHandleThe image handle.
SystemTableThe system table.
Return values
EFI_SUCCESSFunction successfully returned.

Definition at line 712 of file FwVol.c.

◆ GetFvbAuthenticationStatus()

UINT32 GetFvbAuthenticationStatus ( IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL FvbProtocol)

Get FVB authentication status

Parameters
FvbProtocolFVB protocol.
Returns
Authentication status.

Definition at line 396 of file FwVolBlock.c.

◆ GetFwVolHeader()

EFI_STATUS GetFwVolHeader ( IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL Fvb,
OUT EFI_FIRMWARE_VOLUME_HEADER **  FwVolHeader 
)

Given the supplied FW_VOL_BLOCK_PROTOCOL, allocate a buffer for output and copy the real length volume header into it.

Parameters
FvbThe FW_VOL_BLOCK_PROTOCOL instance from which to read the volume header
FwVolHeaderPointer to pointer to allocated buffer in which the volume header is returned.
Return values
EFI_OUT_OF_RESOURCESNo enough buffer could be allocated.
EFI_SUCCESSSuccessfully read volume header to the allocated buffer.
EFI_INVALID_PARAMETERThe FV Header signature is not as expected or the file system could not be understood.

Definition at line 175 of file FwVol.c.

◆ GetSection()

EFI_STATUS EFIAPI GetSection ( IN UINTN  SectionStreamHandle,
IN EFI_SECTION_TYPE *  SectionType,
IN EFI_GUID SectionDefinitionGuid,
IN UINTN  SectionInstance,
IN VOID **  Buffer,
IN OUT UINTN BufferSize,
OUT UINT32 *  AuthenticationStatus,
IN BOOLEAN  IsFfs3Fv 
)

SEP member function. Retrieves requested section from section stream.

Parameters
SectionStreamHandleThe section stream from which to extract the requested section.
SectionTypeA pointer to the type of section to search for.
SectionDefinitionGuidIf the section type is EFI_SECTION_GUID_DEFINED, then SectionDefinitionGuid indicates which of these types of sections to search for.
SectionInstanceIndicates which instance of the requested section to return.
BufferDouble indirection to buffer. If *Buffer is non-null on input, then the buffer is caller allocated. If Buffer is NULL, then the buffer is callee allocated. In either case, the required buffer size is returned in *BufferSize.
BufferSizeOn input, indicates the size of *Buffer if Buffer is non-null on input. On output, indicates the required size (allocated size if callee allocated) of *Buffer.
AuthenticationStatusA pointer to a caller-allocated UINT32 that indicates the authentication status of the output buffer. If the input section's GuidedSectionHeader.Attributes field has the EFI_GUIDED_SECTION_AUTH_STATUS_VALID bit as clear, AuthenticationStatus must return zero. Both local bits (19:16) and aggregate bits (3:0) in AuthenticationStatus are returned by ExtractSection(). These bits reflect the status of the extraction operation. The bit pattern in both regions must be the same, as the local and aggregate authentication statuses have equivalent meaning at this level. If the function returns anything other than EFI_SUCCESS, the value of *AuthenticationStatus is undefined.
IsFfs3FvIndicates the FV format.
Return values
EFI_SUCCESSSection was retrieved successfully
EFI_PROTOCOL_ERRORA GUID defined section was encountered in the section stream with its EFI_GUIDED_SECTION_PROCESSING_REQUIRED bit set, but there was no corresponding GUIDed Section Extraction Protocol in the handle database. Buffer is unmodified.
EFI_NOT_FOUNDAn error was encountered when parsing the SectionStream. This indicates the SectionStream is not correctly formatted.
EFI_NOT_FOUNDThe requested section does not exist.
EFI_OUT_OF_RESOURCESThe system has insufficient resources to process the request.
EFI_INVALID_PARAMETERThe SectionStreamHandle does not exist.
EFI_WARN_TOO_SMALLThe size of the caller allocated input buffer is insufficient to contain the requested section. The input buffer is filled and section contents are truncated.

Definition at line 1242 of file CoreSectionExtraction.c.

◆ InitializeSectionExtraction()

EFI_STATUS EFIAPI InitializeSectionExtraction ( IN EFI_HANDLE  ImageHandle,
IN EFI_SYSTEM_TABLE SystemTable 
)

Entry point of the section extraction code. Initializes an instance of the section extraction interface and installs it on a new handle.

Parameters
ImageHandleA handle for the image that is initializing this driver
SystemTableA pointer to the EFI system table
Return values
EFI_SUCCESSDriver initialized successfully
EFI_OUT_OF_RESOURCESCould not allocate needed resources

Definition at line 212 of file CoreSectionExtraction.c.

◆ InsertImageRecord()

VOID InsertImageRecord ( IN EFI_RUNTIME_IMAGE_ENTRY RuntimeImage)

Insert image record.

Parameters
RuntimeImageRuntime image information

Definition at line 583 of file MemoryAttributesTable.c.

◆ InstallMemoryAttributesTableOnMemoryAllocation()

VOID InstallMemoryAttributesTableOnMemoryAllocation ( IN EFI_MEMORY_TYPE  MemoryType)

Install MemoryAttributesTable on memory allocation.

Parameters
[in]MemoryTypeEFI memory type.

Definition at line 240 of file MemoryAttributesTable.c.

◆ MemoryProfileInit()

VOID MemoryProfileInit ( IN VOID *  HobStart)

Initialize memory profile.

Parameters
HobStartThe start address of the HOB.

Definition at line 592 of file MemoryProfileRecord.c.

◆ MemoryProfileInstallProtocol()

VOID MemoryProfileInstallProtocol ( VOID  )

Install memory profile protocol.

Definition at line 628 of file MemoryProfileRecord.c.

◆ MemoryProtectionExitBootServicesCallback()

VOID MemoryProtectionExitBootServicesCallback ( VOID  )

ExitBootServices Callback function for memory protection.

Definition at line 850 of file MemoryProtection.c.

◆ MergeMemoryMap()

VOID MergeMemoryMap ( IN OUT EFI_MEMORY_DESCRIPTOR MemoryMap,
IN OUT UINTN MemoryMapSize,
IN UINTN  DescriptorSize 
)

Merge continous memory map entries whose have same attributes.

Parameters
MemoryMapA pointer to the buffer in which firmware places the current memory map.
MemoryMapSizeA pointer to the size, in bytes, of the MemoryMap buffer. On input, this is the size of the current memory map. On output, it is the size of new memory map after merge.
DescriptorSizeSize, in bytes, of an individual EFI_MEMORY_DESCRIPTOR.

Merge continuous memory map entries whose have same attributes.

Parameters
[in,out]MemoryMapA pointer to the buffer in which firmware places the current memory map.
[in,out]MemoryMapSizeA pointer to the size, in bytes, of the MemoryMap buffer. On input, this is the size of the current memory map. On output, it is the size of new memory map after merge.
[in]DescriptorSizeSize, in bytes, of an individual EFI_MEMORY_DESCRIPTOR.

Definition at line 382 of file MemoryAttributesTable.c.

◆ OpenSectionStream()

EFI_STATUS EFIAPI OpenSectionStream ( IN UINTN  SectionStreamLength,
IN VOID *  SectionStream,
OUT UINTN SectionStreamHandle 
)

SEP member function. This function creates and returns a new section stream handle to represent the new section stream.

Parameters
SectionStreamLengthSize in bytes of the section stream.
SectionStreamBuffer containing the new section stream.
SectionStreamHandleA pointer to a caller allocated UINTN that on output contains the new section stream handle.
Return values
EFI_SUCCESSThe section stream is created successfully.
EFI_OUT_OF_RESOURCESmemory allocation failed.
EFI_INVALID_PARAMETERSection stream does not end concident with end of last section.

Definition at line 418 of file CoreSectionExtraction.c.

◆ ProduceFVBProtocolOnBuffer()

EFI_STATUS ProduceFVBProtocolOnBuffer ( IN EFI_PHYSICAL_ADDRESS  BaseAddress,
IN UINT64  Length,
IN EFI_HANDLE  ParentHandle,
IN UINT32  AuthenticationStatus,
OUT EFI_HANDLE *FvProtocol  OPTIONAL 
)

This routine produces a firmware volume block protocol on a given buffer.

Parameters
BaseAddressbase address of the firmware volume image
Lengthlength of the firmware volume image
ParentHandlehandle of parent firmware volume, if this image came from an FV image file and section in another firmware volume (ala capsules)
AuthenticationStatusAuthentication status inherited, if this image came from an FV image file and section in another firmware volume.
FvProtocolFirmware volume block protocol produced.
Return values
EFI_VOLUME_CORRUPTEDVolume corrupted.
EFI_OUT_OF_RESOURCESNo enough buffer to be allocated.
EFI_SUCCESSSuccessfully produced a FVB protocol on given buffer.

Definition at line 432 of file FwVolBlock.c.

◆ ProtectUefiImage()

VOID ProtectUefiImage ( IN EFI_LOADED_IMAGE_PROTOCOL LoadedImage,
IN EFI_DEVICE_PATH_PROTOCOL LoadedImageDevicePath 
)

Protect UEFI image.

Parameters
[in]LoadedImageThe loaded image protocol
[in]LoadedImageDevicePathThe loaded image device path protocol

Protect UEFI PE/COFF image.

Parameters
[in]LoadedImageThe loaded image protocol
[in]LoadedImageDevicePathThe loaded image device path protocol

Definition at line 330 of file MemoryProtection.c.

◆ ReadFvbData()

EFI_STATUS ReadFvbData ( IN EFI_FIRMWARE_VOLUME_BLOCK_PROTOCOL Fvb,
IN OUT EFI_LBA StartLba,
IN OUT UINTN Offset,
IN UINTN  DataSize,
OUT UINT8 *  Data 
)

Read data from Firmware Block by FVB protocol Read. The data may cross the multi block ranges.

Parameters
FvbThe FW_VOL_BLOCK_PROTOCOL instance from which to read data.
StartLbaPointer to StartLba. On input, the start logical block index from which to read. On output,the end logical block index after reading.
OffsetPointer to Offset On input, offset into the block at which to begin reading. On output, offset into the end block after reading.
DataSizeSize of data to be read.
DataPointer to Buffer that the data will be read into.
Return values
EFI_SUCCESSSuccessfully read data from firmware block.
others

Definition at line 69 of file FwVol.c.

◆ RegisterMemoryProfileImage()

EFI_STATUS RegisterMemoryProfileImage ( IN LOADED_IMAGE_PRIVATE_DATA DriverEntry,
IN EFI_FV_FILETYPE  FileType 
)

Register image to memory profile.

Parameters
DriverEntryImage info.
FileTypeImage file type.
Returns
EFI_SUCCESS Register successfully.
EFI_UNSUPPORTED Memory profile unsupported, or memory profile for the image is not required.
EFI_OUT_OF_RESOURCES No enough resource for this register.

Register image to memory profile.

Parameters
DriverEntryImage info.
FileTypeImage file type.
Returns
EFI_SUCCESS Register successfully.
EFI_UNSUPPORTED Memory profile is unsupported, or memory profile for the image is not required.
EFI_OUT_OF_RESOURCES No enough resource for this register.

Definition at line 694 of file MemoryProfileRecord.c.

◆ RemoveImageRecord()

VOID RemoveImageRecord ( IN EFI_RUNTIME_IMAGE_ENTRY RuntimeImage)

Remove Image record.

Parameters
RuntimeImageRuntime image information

Definition at line 672 of file MemoryAttributesTable.c.

◆ UnprotectUefiImage()

VOID UnprotectUefiImage ( IN EFI_LOADED_IMAGE_PROTOCOL LoadedImage,
IN EFI_DEVICE_PATH_PROTOCOL LoadedImageDevicePath 
)

Unprotect UEFI image.

Parameters
[in]LoadedImageThe loaded image protocol
[in]LoadedImageDevicePathThe loaded image device path protocol

Definition at line 399 of file MemoryProtection.c.

◆ UnregisterMemoryProfileImage()

EFI_STATUS UnregisterMemoryProfileImage ( IN LOADED_IMAGE_PRIVATE_DATA DriverEntry)

Unregister image from memory profile.

Parameters
DriverEntryImage info.
Returns
EFI_SUCCESS Unregister successfully.
EFI_UNSUPPORTED Memory profile unsupported, or memory profile for the image is not required.
EFI_NOT_FOUND The image is not found.

Unregister image from memory profile.

Parameters
DriverEntryImage info.
Returns
EFI_SUCCESS Unregister successfully.
EFI_UNSUPPORTED Memory profile is unsupported, or memory profile for the image is not required.
EFI_NOT_FOUND The image is not found.

Definition at line 833 of file MemoryProfileRecord.c.

◆ VerifyFvHeaderChecksum()

BOOLEAN VerifyFvHeaderChecksum ( IN EFI_FIRMWARE_VOLUME_HEADER FvHeader)

Verify checksum of the firmware volume header.

Parameters
FvHeaderPoints to the firmware volume header to be checked
Return values
TRUEChecksum verification passed
FALSEChecksum verification failed

Definition at line 92 of file Ffs.c.

Variable Documentation

◆ gBds

EFI_BDS_ARCH_PROTOCOL* gBds
extern

BDS arch protocol instance initial value.

Definition at line 24 of file DxeMain.c.

◆ gCpu

EFI_CPU_ARCH_PROTOCOL* gCpu
extern

Definition at line 21 of file DxeMain.c.

◆ gDispatcherRunning

BOOLEAN gDispatcherRunning
extern

Definition at line 61 of file Dispatcher.c.

◆ gDxeCoreDS

EFI_DXE_SERVICES* gDxeCoreDS
extern

Definition at line 193 of file DxeMain.c.

◆ gDxeCoreFileName

EFI_GUID* gDxeCoreFileName
extern

Definition at line 35 of file DxeMain.c.

◆ gDxeCoreImageHandle

EFI_HANDLE gDxeCoreImageHandle
extern

Definition at line 202 of file DxeMain.c.

◆ gDxeCoreLoadedImage

EFI_LOADED_IMAGE_PROTOCOL* gDxeCoreLoadedImage
extern

Definition at line 36 of file DxeMain.c.

◆ gDxeCoreRT

EFI_RUNTIME_SERVICES* gDxeCoreRT
extern

Definition at line 201 of file DxeMain.c.

◆ gDxeCoreST

EFI_SYSTEM_TABLE* gDxeCoreST
extern

Definition at line 194 of file DxeMain.c.

◆ gEfiCurrentTpl

EFI_TPL gEfiCurrentTpl
extern

gEfiCurrentTpl - Current Task priority level

Definition at line 16 of file Event.c.

◆ gEfiDecompress

EFI_DECOMPRESS_PROTOCOL gEfiDecompress
extern

Definition at line 209 of file DxeMain.c.

◆ gLoadFixedAddressCodeMemoryReady

BOOLEAN gLoadFixedAddressCodeMemoryReady
extern

Definition at line 96 of file Page.c.

◆ gLoadModuleAtFixAddressConfigurationTable

EFI_LOAD_FIXED_ADDRESS_CONFIGURATION_TABLE gLoadModuleAtFixAddressConfigurationTable
extern

Definition at line 218 of file DxeMain.c.

◆ gMemoryAttributesTableForwardCfi

BOOLEAN gMemoryAttributesTableForwardCfi
extern

Definition at line 93 of file MemoryAttributesTable.c.

◆ gMemoryMapTerminated

BOOLEAN gMemoryMapTerminated
extern

Definition at line 204 of file DxeMain.c.

◆ gMemoryTypeInformation

EFI_MEMORY_TYPE_INFORMATION gMemoryTypeInformation[EfiMaxMemoryType+1]
extern

Definition at line 72 of file Page.c.

◆ gMetronome

EFI_METRONOME_ARCH_PROTOCOL* gMetronome
extern

Interface structure for the Metronome Architectural Protocol.

Protocol Description:
This protocol provides access to a known time source in the platform to the core. The core uses this known time source to produce core services that require calibrated delays.
Parameters
WaitForTickWaits for a specified number of ticks from a known time source in the platform. The actual time passed between entry of this function and the first tick is between 0 and TickPeriod 100 nS units. If you want to guarantee that at least TickPeriod time has elapsed, wait for two ticks.
TickPeriodThe period of platform's known time source in 100 nS units. This value on any platform must not exceed 200 uS. The value in this field is a constant that must not be modified after the Metronome architectural protocol is installed. All consumers must treat this as a read-only field.

Definition at line 51 of file Metronome.c.

◆ gRuntime

EFI_RUNTIME_ARCH_PROTOCOL* gRuntime
extern

Definition at line 187 of file DxeMain.c.

◆ gRuntimeTemplate

EFI_RUNTIME_ARCH_PROTOCOL gRuntimeTemplate
extern

Definition at line 169 of file DxeMain.c.

◆ gSecurity

EFI_SECURITY_ARCH_PROTOCOL* gSecurity
extern

Definition at line 19 of file DxeMain.c.

◆ gSecurity2

EFI_SECURITY2_ARCH_PROTOCOL* gSecurity2
extern

Definition at line 20 of file DxeMain.c.

◆ gSmmBase2

EFI_SMM_BASE2_PROTOCOL* gSmmBase2
extern

Definition at line 30 of file DxeMain.c.

◆ gTimer

EFI_TIMER_ARCH_PROTOCOL* gTimer
extern

Interface structure for the Timer Architectural Protocol.

Protocol Description:
This protocol provides the services to initialize a periodic timer interrupt, and to register a handler that is called each time the timer interrupt fires. It may also provide a service to adjust the rate of the periodic timer interrupt. When a timer interrupt occurs, the handler is passed the amount of time that has passed since the previous timer interrupt.
Parameters
RegisterHandlerRegisters a handler that will be called each time the timer interrupt fires. TimerPeriod defines the minimum time between timer interrupts, so TimerPeriod will also be the minimum time between calls to the registered handler.
SetTimerPeriodSets the period of the timer interrupt in 100 nS units. This function is optional, and may return EFI_UNSUPPORTED. If this function is supported, then the timer period will be rounded up to the nearest supported timer period.
GetTimerPeriodRetrieves the period of the timer interrupt in 100 nS units.
GenerateSoftInterruptGenerates a soft timer interrupt that simulates the firing of the timer interrupt. This service can be used to invoke the registered handler if the timer interrupt has been masked for a period of time.

Definition at line 264 of file TimerDxe.c.

◆ gWatchdogTimer

EFI_WATCHDOG_TIMER_ARCH_PROTOCOL* gWatchdogTimer
extern

Definition at line 25 of file DxeMain.c.