2 EBC Simple Debugger protocol for debug EBC code.
4 Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
6 This program and the accompanying materials
7 are licensed and made available under the terms and conditions
8 of the BSD License which accompanies this distribution. The
9 full text of the license may be found at
10 http://opensource.org/licenses/bsd-license.php
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
17 #ifndef _EBC_SIMPLE_DEBUGGER_PROTOCOL_H_
18 #define _EBC_SIMPLE_DEBUGGER_PROTOCOL_H_
20 #include <Protocol/DebugSupport.h>
21 #include <Protocol/EbcVmTest.h>
23 #define EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL_GUID \
25 0x2a72d11e, 0x7376, 0x40f6, { 0x9c, 0x68, 0x23, 0xfa, 0x2f, 0xe3, 0x63, 0xf1 } \
29 // Defines for a simple EBC debugger interface
31 typedef struct _EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
;
34 Trig Exception on EBC VM.
36 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
37 @param[in] VmPtr A pointer to a VM context.
38 @param[in] ExceptionType Exception to be trigged.
40 @retval EFI_UNSUPPORTED No support for it.
41 @retval EFI_SUCCESS Exception is trigged.
46 (EFIAPI
*EBC_DEBUGGER_SIGNAL_EXCEPTION
) (
47 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
49 IN EFI_EXCEPTION_TYPE ExceptionType
53 Given a pointer to a new VM context, debug one or more instructions.
55 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
56 @param[in] VmPtr A pointer to a VM context.
58 @retval EFI_UNSUPPORTED No support for it.
59 @retval EFI_SUCCESS Debug one or more instructions.
64 (EFIAPI
*EBC_DEBUGGER_DEBUG
) (
65 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
70 Given a pointer to a new VM context, dump one or more instructions.
72 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
73 @param[in] VmPtr A pointer to a VM context.
74 @param[in] DasmString Dump string buffer.
75 @param[in] DasmStringSize Dump string size.
77 @retval EFI_UNSUPPORTED No support for it.
78 @retval EFI_SUCCESS Dump one or more instructions.
83 (EFIAPI
*EBC_DEBUGGER_DASM
) (
84 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
86 IN UINT16
*DasmString OPTIONAL
,
87 IN UINT32 DasmStringSize
91 This interface allows you to configure the EBC debug support
92 driver. For example, turn on or off saving and printing of
93 delta VM even if called. Or to even disable the entire interface,
94 in which case all functions become no-ops.
96 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
97 @param[in] ConfigId ID to be configured.
98 @param[in] ConfigValue Value to be set.
100 @retval EFI_UNSUPPORTED No support for it.
101 @retval EFI_SUCCESS Configure EBC debug.
106 (EFIAPI
*EBC_DEBUGGER_CONFIGURE
) (
107 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
113 // Prototype for the actual EBC debug support protocol interface
115 struct _EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
{
116 EBC_DEBUGGER_DEBUG Debugger
;
117 EBC_DEBUGGER_SIGNAL_EXCEPTION SignalException
;
118 EBC_DEBUGGER_DASM Dasm
;
119 EBC_DEBUGGER_CONFIGURE Configure
;
122 extern EFI_GUID gEfiEbcSimpleDebuggerProtocolGuid
;