TianoCore EDK2 master
|
#include "DxeDebugAgentLib.h"
Go to the source code of this file.
Functions | |
BOOLEAN | MultiProcessorDebugSupport (VOID) |
VOID | InternalConstructorWorker (VOID) |
RETURN_STATUS EFIAPI | DxeDebugAgentLibConstructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable) |
DEBUG_AGENT_MAILBOX * | GetMailboxFromConfigurationTable (VOID) |
DEBUG_AGENT_MAILBOX * | GetMailboxFromHob (IN VOID *HobStart) |
DEBUG_AGENT_MAILBOX * | GetMailboxPointer (VOID) |
DEBUG_PORT_HANDLE | GetDebugPortHandle (VOID) |
VOID | SetupDebugAgentEnvironment (IN DEBUG_AGENT_MAILBOX *Mailbox) |
VOID EFIAPI | InitializeDebugAgent (IN UINT32 InitFlag, IN VOID *Context OPTIONAL, IN DEBUG_AGENT_CONTINUE Function OPTIONAL) |
Variables | |
DEBUG_AGENT_MAILBOX | mMailbox |
DEBUG_AGENT_MAILBOX * | mMailboxPointer = NULL |
IA32_IDT_GATE_DESCRIPTOR | mIdtEntryTable [33] |
BOOLEAN | mDxeCoreFlag = FALSE |
BOOLEAN | mMultiProcessorDebugSupport = FALSE |
VOID * | mSavedIdtTable = NULL |
UINTN | mSaveIdtTableSize = 0 |
BOOLEAN | mDebugAgentInitialized = FALSE |
BOOLEAN | mSkipBreakpoint = FALSE |
Debug Agent library implementation for Dxe Core and Dxr modules.
Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent
Definition in file DxeDebugAgentLib.c.
RETURN_STATUS EFIAPI DxeDebugAgentLibConstructor | ( | IN EFI_HANDLE | ImageHandle, |
IN EFI_SYSTEM_TABLE * | SystemTable | ||
) |
Debug Agent constructor function.
[in] | ImageHandle | The firmware allocated handle for the EFI image. |
[in] | SystemTable | A pointer to the EFI System Table. |
RETURN_SUCCESS | When this function completed. |
Definition at line 135 of file DxeDebugAgentLib.c.
DEBUG_PORT_HANDLE GetDebugPortHandle | ( | VOID | ) |
DEBUG_AGENT_MAILBOX * GetMailboxFromConfigurationTable | ( | VOID | ) |
Get the pointer to Mailbox from the configuration table.
Definition at line 157 of file DxeDebugAgentLib.c.
DEBUG_AGENT_MAILBOX * GetMailboxFromHob | ( | IN VOID * | HobStart | ) |
Get the pointer to Mailbox from the GUIDed HOB.
[in] | HobStart | The starting HOB pointer to search from. |
Definition at line 182 of file DxeDebugAgentLib.c.
DEBUG_AGENT_MAILBOX * GetMailboxPointer | ( | VOID | ) |
Get Debug Agent Mailbox pointer.
Definition at line 209 of file DxeDebugAgentLib.c.
VOID EFIAPI InitializeDebugAgent | ( | IN UINT32 | InitFlag, |
IN VOID *Context | OPTIONAL, | ||
IN DEBUG_AGENT_CONTINUE Function | OPTIONAL | ||
) |
Initialize debug agent.
This function is used to set up debug environment for DXE phase.
If this function is called by DXE Core, Context must be the pointer to HOB list which will be used to get GUIDed HOB. It will enable interrupt to support break-in feature. If this function is called by DXE module, Context must be NULL. It will enable interrupt to support break-in feature.
[in] | InitFlag | Init flag is used to decide initialize process. |
[in] | Context | Context needed according to InitFlag. |
[in] | Function | Continue function called by debug agent library; it was optional. |
Definition at line 351 of file DxeDebugAgentLib.c.
VOID InternalConstructorWorker | ( | VOID | ) |
Internal constructor worker function.
It will register one callback function on EFI PCD Protocol. It will allocate the NVS memory to store Mailbox and install configuration table in system table to store its pointer.
Definition at line 45 of file DxeDebugAgentLib.c.
BOOLEAN MultiProcessorDebugSupport | ( | VOID | ) |
Check if debug agent support multi-processor.
TRUE | Multi-processor is supported. |
FALSE | Multi-processor is not supported. |
Definition at line 29 of file DxeDebugAgentLib.c.
VOID SetupDebugAgentEnvironment | ( | IN DEBUG_AGENT_MAILBOX * | Mailbox | ) |
Worker function to set up Debug Agent environment.
This function will set up IDT table and initialize the IDT entries and initialize CPU LOCAL APIC timer. It also tries to connect HOST if Debug Agent was not initialized before.
[in] | Mailbox | Pointer to Mailbox. |
Definition at line 244 of file DxeDebugAgentLib.c.
BOOLEAN mDebugAgentInitialized = FALSE |
Definition at line 18 of file DxeDebugAgentLib.c.
BOOLEAN mDxeCoreFlag = FALSE |
Definition at line 14 of file DxeDebugAgentLib.c.
IA32_IDT_GATE_DESCRIPTOR mIdtEntryTable[33] |
Definition at line 13 of file DxeDebugAgentLib.c.
DEBUG_AGENT_MAILBOX mMailbox |
Definition at line 11 of file DxeDebugAgentLib.c.
DEBUG_AGENT_MAILBOX* mMailboxPointer = NULL |
Definition at line 12 of file DxeDebugAgentLib.c.
BOOLEAN mMultiProcessorDebugSupport = FALSE |
Definition at line 15 of file DxeDebugAgentLib.c.
VOID* mSavedIdtTable = NULL |
Definition at line 16 of file DxeDebugAgentLib.c.
UINTN mSaveIdtTableSize = 0 |
Definition at line 17 of file DxeDebugAgentLib.c.
BOOLEAN mSkipBreakpoint = FALSE |
Definition at line 19 of file DxeDebugAgentLib.c.