2 EBC Simple Debugger protocol for debug EBC code.
4 Copyright (c) 2011 - 2018, Intel Corporation. All rights reserved.<BR>
6 SPDX-License-Identifier: BSD-2-Clause-Patent
10 #ifndef _EBC_SIMPLE_DEBUGGER_PROTOCOL_H_
11 #define _EBC_SIMPLE_DEBUGGER_PROTOCOL_H_
13 #include <Protocol/DebugSupport.h>
14 #include <Protocol/EbcVmTest.h>
16 #define EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL_GUID \
18 0x2a72d11e, 0x7376, 0x40f6, { 0x9c, 0x68, 0x23, 0xfa, 0x2f, 0xe3, 0x63, 0xf1 } \
22 // Defines for a simple EBC debugger interface
24 typedef struct _EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
;
27 Trig Exception on EBC VM.
29 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
30 @param[in] VmPtr A pointer to a VM context.
31 @param[in] ExceptionType Exception to be trigged.
33 @retval EFI_UNSUPPORTED No support for it.
34 @retval EFI_SUCCESS Exception is trigged.
39 (EFIAPI
*EBC_DEBUGGER_SIGNAL_EXCEPTION
) (
40 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
42 IN EFI_EXCEPTION_TYPE ExceptionType
46 Given a pointer to a new VM context, debug one or more instructions.
48 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
49 @param[in] VmPtr A pointer to a VM context.
51 @retval EFI_UNSUPPORTED No support for it.
52 @retval EFI_SUCCESS Debug one or more instructions.
57 (EFIAPI
*EBC_DEBUGGER_DEBUG
) (
58 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
63 Given a pointer to a new VM context, dump one or more instructions.
65 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
66 @param[in] VmPtr A pointer to a VM context.
67 @param[in] DasmString Dump string buffer.
68 @param[in] DasmStringSize Dump string size.
70 @retval EFI_UNSUPPORTED No support for it.
71 @retval EFI_SUCCESS Dump one or more instructions.
76 (EFIAPI
*EBC_DEBUGGER_DASM
) (
77 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
79 IN UINT16
*DasmString OPTIONAL
,
80 IN UINT32 DasmStringSize
84 This interface allows you to configure the EBC debug support
85 driver. For example, turn on or off saving and printing of
86 delta VM even if called. Or to even disable the entire interface,
87 in which case all functions become no-ops.
89 @param[in] This A pointer to the EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL structure.
90 @param[in] ConfigId ID to be configured.
91 @param[in] ConfigValue Value to be set.
93 @retval EFI_UNSUPPORTED No support for it.
94 @retval EFI_SUCCESS Configure EBC debug.
99 (EFIAPI
*EBC_DEBUGGER_CONFIGURE
) (
100 IN EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
*This
,
106 // Prototype for the actual EBC debug support protocol interface
108 struct _EFI_EBC_SIMPLE_DEBUGGER_PROTOCOL
{
109 EBC_DEBUGGER_DEBUG Debugger
;
110 EBC_DEBUGGER_SIGNAL_EXCEPTION SignalException
;
111 EBC_DEBUGGER_DASM Dasm
;
112 EBC_DEBUGGER_CONFIGURE Configure
;
115 extern EFI_GUID gEfiEbcSimpleDebuggerProtocolGuid
;