📄 dbg_rdi.h
字号:
/* * Copyright (C) 1995 Advanced RISC Machines Limited. All rights reserved. * * This software may be freely used, copied, modified, and distributed * provided that the above copyright notice is preserved in all copies of the * software. *//* * ARM debugger toolbox : dbg_rdi.h *//* * RCS $Revision: 1.2 $ * Checkin $Date: 1998/01/08 11:11:53 $ */#ifndef dbg_rdi__h#define dbg_rdi__h/***************************************************************************\* Other RDI values *\***************************************************************************/#define RDISex_Little 0 /* the byte sex of the debuggee */#define RDISex_Big 1#define RDISex_DontCare 2#define RDIPoint_EQ 0 /* the different types of break/watchpoints */#define RDIPoint_GT 1#define RDIPoint_GE 2#define RDIPoint_LT 3#define RDIPoint_LE 4#define RDIPoint_IN 5#define RDIPoint_OUT 6#define RDIPoint_MASK 7#define RDIPoint_16Bit 16 /* 16-bit breakpoint */#define RDIPoint_Conditional 32/* ORRed with point type in extended RDP break and watch messages */#define RDIPoint_Inquiry 64#define RDIPoint_Handle 128 /* messages */#define RDIWatch_ByteRead 1 /* types of data accesses to watch for*/#define RDIWatch_HalfRead 2#define RDIWatch_WordRead 4#define RDIWatch_ByteWrite 8#define RDIWatch_HalfWrite 16#define RDIWatch_WordWrite 32#define RDIReg_R15 (1L << 15) /* mask values for CPU */#define RDIReg_PC (1L << 16)#define RDIReg_CPSR (1L << 17)#define RDIReg_SPSR (1L << 18)#define RDINumCPURegs 19#define RDINumCPRegs 10 /* current maximum */#define RDIMode_Curr 255/* RDI_Info subcodes *//* rdp in parameters are all preceded by *//* in byte = RDP_Info, word = info subcode *//* out parameters are all preceded by *//* out byte = RDP_Return */#define RDIInfo_Target 0/* rdi: out ARMword *targetflags, out ARMword *processor id *//* rdp: in none, out word targetflags, word processorid, byte status *//* the following bits are defined in targetflags */# define RDITarget_LogSpeed 0x0f# define RDITarget_HW 0x10 /* else emulator */# define RDITarget_AgentMaxLevel 0xe0# define RDITarget_AgentLevelShift 5# define RDITarget_DebuggerMinLevel 0x700# define RDITarget_DebuggerLevelShift 8# define RDITarget_CanReloadAgent 0x800# define RDITarget_CanInquireLoadSize 0x1000# define RDITarget_UnderstandsRDPInterrupt 0x2000# define RDITarget_CanProfile 0x4000# define RDITarget_Code16 0x8000# define RDITarget_HasCommsChannel 0x10000#define RDIInfo_Points 1/* rdi: out ARMword *pointcapabilities *//* rdp: in none, out word pointcapabilities, byte status *//* the following bits are defined in pointcapabilities */# define RDIPointCapability_Comparison 1# define RDIPointCapability_Range 2/* 4 to 128 are RDIWatch_xx{Read,Write} left-shifted by two */# define RDIPointCapability_Mask 0x100# define RDIPointCapability_ThreadBreak 0x200# define RDIPointCapability_ThreadWatch 0x400# define RDIPointCapability_CondBreak 0x800# define RDIPointCapability_Status 0x1000 /* status enquiries available */#define RDIInfo_Step 2/* rdi: out ARMword *stepcapabilities *//* rdp: in none, out word stepcapabilities, byte status *//* the following bits are defined in stepcapabilities */# define RDIStep_Multiple 1# define RDIStep_PCChange 2# define RDIStep_Single 4#define RDIInfo_MMU 3/* rdi: out ARMword *mmuidentity *//* rdp: in none, out word mmuidentity, byte status */#define RDIInfo_DownLoad 4/* Inquires whether configuration download and selection is available. *//* rdp: in none, out byte status *//* No argument, no return value. status == ok if available */#define RDIInfo_SemiHosting 5/* Inquires whether RDISemiHosting_* RDI_Info calls are available. *//* rdp: in none, out byte status *//* No argument, no return value. status == ok if available */#define RDIInfo_CoPro 6/* Inquires whether CoPro RDI_Info calls are available. *//* rdp: in none, out byte status *//* No argument, no return value. status == ok if available */#define RDIInfo_Icebreaker 7/* Inquires whether debuggee controlled by IceBreaker. *//* rdp: in none, out byte status *//* No argument, no return value. status == ok if available */#define RDIMemory_Access 8/* rdi: out RDI_MemAccessStats *p, in ARMword *handle *//* rdp: in word handle *//* out word nreads, word nwrites, word sreads, word swrites, *//* word ns, word s, byte status *//* Get memory access information for memory block with specified handle */#define RDIMemory_Map 9/* rdi: in RDI_MemDescr md[n], in ARMword *n *//* rdp: in word n, n * { *//* word handle, word start, word limit, *//* byte width, byte access *//* word Nread_ns, word Nwrite_ns, *//* word Sread_ns, word Swrite_ns} *//* out byte status *//* Sets memory characteristics. */#define RDISet_CPUSpeed 10/* rdi: in ARMword *speed *//* rdp: in word speed, out byte status *//* Sets CPU speed (in ns) */#define RDIRead_Clock 12/* rdi: out ARMword *ns, out ARMword *s *//* rdp: in none, out word ns, word s, byte status *//* Reads simulated time */#define RDIInfo_Memory_Stats 13/* Inquires whether RDI_Info codes 8-10 are available *//* rdp: in none, out byte status *//* No argument, no return value. status == ok if available *//* The next two are only to be used if RDIInfo_DownLoad returned no *//* error */#define RDIConfig_Count 14/* rdi: out ARMword *count *//* rdp: out byte status, word count (if status == OK) *//* In addition, the next one is only to be used if RDIConfig_Count *//* returned no error */typedef struct { unsigned32 version; char name[32]; } RDI_ConfigDesc;#define RDIConfig_Nth 15/* rdi: in ARMword *n, out RDI_ConfigDesc * *//* rdp: in word n *//* out word version, byte namelen, bytes * bytelen name, *//* byte status *//* Set a front-end polling function to be used from within driver poll *//* loops */typedef void RDI_PollProc(void *);typedef struct { RDI_PollProc *p; void *arg; } RDI_PollDesc;#define RDISet_PollProc 16/* rdi: in RDI_PollDesc const *from, RDI_PollDesc *to *//* if from non-NULL, sets the polling function from it *//* if to non-NULL, returns the previous polling function to it *//* No corresponding RDP operation *//* Called on debugger startup to see if the target is ready to execute */#define RDIInfo_CanTargetExecute 20/* rdi: in void * out byte status (RDIError_NoError => Yes, Otherwise No) *//* Called to set the top of target memory in an ICEman2 system * This is then used by ICEman to tell the C Library via the INFOHEAP * SWI where the stack should start. * Note that only ICEman2 supports this call. Other systems eg. * Demon, Angel, will simply return an error, which means that setting * the top of memory in this fashion is not supported. */#define RDIInfo_SetTopMem 21/* rdi: in word mem_top * out byte status (RDIError_NoError => Done, Other => Not supported *//* Called before performing a loadagent to determine the endianess of * the debug agent, so that images of the wrong bytesex can be * complained about */#define RDIInfo_AgentEndianess 22/* rdi: in void * out byte status * status should be RDIError_LittleEndian or RDIError_BigEndian * any other value indicates the target does not support this * request, so the debugger will have to make a best guess, which * probably means only allow little endian loadagenting. *//* The next two are only to be used if the value returned by *//* RDIInfo_Points has RDIPointCapability_Status set. */#define RDIPointStatus_Watch 0x80#define RDIPointStatus_Break 0x81/* rdi: inout ARMword * (in handle, out hwresource), out ARMword *type *//* rdp: in word handle, out word hwresource, word type, byte status */#define RDISignal_Stop 0x100/* Requests that the debuggee stop *//* No arguments, no return value *//* rdp: no reply (when the debuggee stops, there will be a reply to the *//* step or execute request which started it) */#define RDIVector_Catch 0x180/* rdi: in ARMword *bitmap *//* rdp: int word bitmap, out byte status *//* bit i in bitmap set to cause vector i to cause entry to debugger *//* The next four are only to be used if RDIInfo_Semihosting returned *//* no error */#define RDISemiHosting_SetState 0x181/* rdi: in ARMword *semihostingstate *//* rdp: in word semihostingstate, out byte status */#define RDISemiHosting_GetState 0x182/* rdi: out ARMword *semihostingstate *//* rdp: in none, out word semihostingstate, byte status */#define RDISemiHosting_SetVector 0x183/* rdi: in ARMword *semihostingvector *//* rdp: in word semihostingvector, out byte status */#define RDISemiHosting_GetVector 0x184/* rdi: out ARMword *semihostingvector *//* rdp: in none, out word semihostingvector, byte status *//* The next two are only to be used if RDIInfo_Icebreaker returned *//* no error */#define RDIIcebreaker_GetLocks 0x185/* rdi: out ARMword *lockedstate *//* rdp: in none, out word lockedstate, byte status */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -