]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Include/Library/DebugAgentLib.h
1. Refine debug agent library.
[mirror_edk2.git] / MdeModulePkg / Include / Library / DebugAgentLib.h
1 /** @file
2 Debug Agent Library provide source-level debug capability.
3
4 Copyright (c) 2010, Intel Corporation
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 **/
14
15 #ifndef __DEBUG_AGENT_LIB_H__
16 #define __DEBUG_AGENT_LIB_H__
17
18 #define DEBUG_AGENT_INIT_PREMEM_SEC 1
19 #define DEBUG_AGENT_INIT_POSTMEM_SEC 2
20 #define DEBUG_AGENT_INIT_DXE 3
21 #define DEBUG_AGENT_INIT_SMM 4
22 #define DEBUG_AGENT_INIT_ENTER_SMI 5
23 #define DEBUG_AGENT_INIT_EXIT_SMI 6
24
25 /**
26 Initialize debug agent.
27
28 This function is used to set up debug enviroment.
29
30 @param[in] InitFlag Init flag is used to decide initialize process.
31 @param[in] Context Context needed according to InitFlag, it was optional.
32
33 **/
34 VOID
35 EFIAPI
36 InitializeDebugAgent (
37 IN UINT32 InitFlag,
38 IN VOID *Context OPTIONAL
39 );
40
41 /**
42 Enable/Disable the interrupt of debug timer and return the interrupt state
43 prior to the operation.
44
45 If EnableStatus is TRUE, enable the interrupt of debug timer.
46 If EnableStatus is FALSE, disable the interrupt of debug timer.
47
48 @param[in] EnableStatus Enable/Disable.
49
50 @retval TRUE Debug timer interrupt were enabled on entry to this call.
51 @retval FALSE Debug timer interrupt were disabled on entry to this call.
52
53 **/
54 BOOLEAN
55 EFIAPI
56 SaveAndSetDebugTimerInterrupt (
57 IN BOOLEAN EnableStatus
58 );
59
60 #endif