OpenOCD
etm.h File Reference
Include dependency graph for etm.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  etm_capture_driver
 
struct  etm_context
 
struct  etm_reg
 
struct  etmv1_trace_data
 

Macros

#define ERROR_ETM_ANALYSIS_FAILED   (-1303)
 
#define ERROR_ETM_CAPTURE_INIT_FAILED   (-1302)
 
#define ERROR_ETM_INVALID_DRIVER   (-1300)
 
#define ERROR_ETM_PORTMODE_NOT_SUPPORTED   (-1301)
 

Enumerations

enum  {
  ETM_CTRL = 0x00 , ETM_CONFIG = 0x01 , ETM_TRIG_EVENT = 0x02 , ETM_ASIC_CTRL = 0x03 ,
  ETM_STATUS = 0x04 , ETM_SYS_CONFIG = 0x05 , ETM_TRACE_RESOURCE_CTRL = 0x06 , ETM_TRACE_EN_CTRL2 = 0x07 ,
  ETM_TRACE_EN_EVENT = 0x08 , ETM_TRACE_EN_CTRL1 = 0x09 , ETM_FIFOFULL_REGION = 0x0a , ETM_FIFOFULL_LEVEL = 0x0b ,
  ETM_VIEWDATA_EVENT = 0x0c , ETM_VIEWDATA_CTRL1 = 0x0d , ETM_VIEWDATA_CTRL2 = 0x0e , ETM_VIEWDATA_CTRL3 = 0x0f ,
  ETM_ADDR_COMPARATOR_VALUE = 0x10 , ETM_ADDR_ACCESS_TYPE = 0x20 , ETM_DATA_COMPARATOR_VALUE = 0x30 , ETM_DATA_COMPARATOR_MASK = 0x40 ,
  ETM_COUNTER_RELOAD_VALUE = 0x50 , ETM_COUNTER_ENABLE = 0x54 , ETM_COUNTER_RELOAD_EVENT = 0x58 , ETM_COUNTER_VALUE = 0x5c ,
  ETM_SEQUENCER_EVENT = 0x60 , ETM_SEQUENCER_STATE = 0x67 , ETM_EXTERNAL_OUTPUT = 0x68 , ETM_CONTEXTID_COMPARATOR_VALUE = 0x6c ,
  ETM_CONTEXTID_COMPARATOR_MASK = 0x6f , ETM_ID = 0x79
}
 
enum  {
  ETM_CTRL_POWERDOWN = (1 << 0) , ETM_CTRL_MONITOR_CPRT = (1 << 1) , ETM_CTRL_TRACE_DATA = (1 << 2) , ETM_CTRL_TRACE_ADDR = (2 << 2) ,
  ETM_CTRL_TRACE_MASK = (3 << 2) , ETM_PORT_4BIT = 0x00 , ETM_PORT_8BIT = 0x10 , ETM_PORT_16BIT = 0x20 ,
  ETM_PORT_24BIT = 0x30 , ETM_PORT_32BIT = 0x40 , ETM_PORT_48BIT = 0x50 , ETM_PORT_64BIT = 0x60 ,
  ETM_PORT_1BIT = 0x00 | (1 << 21) , ETM_PORT_2BIT = 0x10 | (1 << 21) , ETM_PORT_WIDTH_MASK = 0x70 | (1 << 21) , ETM_CTRL_FIFOFULL_STALL = (1 << 7) ,
  ETM_CTRL_BRANCH_OUTPUT = (1 << 8) , ETM_CTRL_DBGRQ = (1 << 9) , ETM_CTRL_ETM_PROG = (1 << 10) , ETM_CTRL_ETMEN = (1 << 11) ,
  ETM_CTRL_CYCLE_ACCURATE = (1 << 12) , ETM_PORT_FULL_CLOCK = (0 << 13) , ETM_PORT_HALF_CLOCK = (1 << 13) , ETM_PORT_CLOCK_MASK = (1 << 13) ,
  ETM_CTRL_CONTEXTID_NONE = (0 << 14) , ETM_CTRL_CONTEXTID_8 = (1 << 14) , ETM_CTRL_CONTEXTID_16 = (2 << 14) , ETM_CTRL_CONTEXTID_32 = (3 << 14) ,
  ETM_CTRL_CONTEXTID_MASK = (3 << 14) , ETM_PORT_NORMAL = (0 << 16) , ETM_PORT_MUXED = (1 << 16) , ETM_PORT_DEMUXED = (2 << 16) ,
  ETM_PORT_MODE_MASK = (3 << 16)
}
 
enum  { ETMV1_TRACESYNC_CYCLE = 0x1 , ETMV1_TRIGGER_CYCLE = 0x2 }
 
enum  etmv1_branch_reason_t {
  BR_NORMAL = 0x0 , BR_ENABLE = 0x1 , BR_RESTART = 0x2 , BR_NODEBUG = 0x3 ,
  BR_PERIOD = 0x4 , BR_RSVD5 = 0x5 , BR_RSVD6 = 0x6 , BR_RSVD7 = 0x7
}
 
enum  etmv1_pipestat_t {
  STAT_IE = 0x0 , STAT_ID = 0x1 , STAT_IN = 0x2 , STAT_WT = 0x3 ,
  STAT_BE = 0x4 , STAT_BD = 0x5 , STAT_TR = 0x6 , STAT_TD = 0x7
}
 

Functions

struct reg_cacheetm_build_reg_cache (struct target *target, struct arm_jtag *jtag_info, struct etm_context *etm_ctx)
 
int etm_setup (struct target *target)
 

Variables

const struct command_registration etm_command_handlers []
 

Macro Definition Documentation

◆ ERROR_ETM_ANALYSIS_FAILED

#define ERROR_ETM_ANALYSIS_FAILED   (-1303)

Definition at line 211 of file etm.h.

◆ ERROR_ETM_CAPTURE_INIT_FAILED

#define ERROR_ETM_CAPTURE_INIT_FAILED   (-1302)

Definition at line 210 of file etm.h.

◆ ERROR_ETM_INVALID_DRIVER

#define ERROR_ETM_INVALID_DRIVER   (-1300)

Definition at line 208 of file etm.h.

◆ ERROR_ETM_PORTMODE_NOT_SUPPORTED

#define ERROR_ETM_PORTMODE_NOT_SUPPORTED   (-1301)

Definition at line 209 of file etm.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
ETM_CTRL 
ETM_CONFIG 
ETM_TRIG_EVENT 
ETM_ASIC_CTRL 
ETM_STATUS 
ETM_SYS_CONFIG 
ETM_TRACE_RESOURCE_CTRL 
ETM_TRACE_EN_CTRL2 
ETM_TRACE_EN_EVENT 
ETM_TRACE_EN_CTRL1 
ETM_FIFOFULL_REGION 
ETM_FIFOFULL_LEVEL 
ETM_VIEWDATA_EVENT 
ETM_VIEWDATA_CTRL1 
ETM_VIEWDATA_CTRL2 
ETM_VIEWDATA_CTRL3 
ETM_ADDR_COMPARATOR_VALUE 
ETM_ADDR_ACCESS_TYPE 
ETM_DATA_COMPARATOR_VALUE 
ETM_DATA_COMPARATOR_MASK 
ETM_COUNTER_RELOAD_VALUE 
ETM_COUNTER_ENABLE 
ETM_COUNTER_RELOAD_EVENT 
ETM_COUNTER_VALUE 
ETM_SEQUENCER_EVENT 
ETM_SEQUENCER_STATE 
ETM_EXTERNAL_OUTPUT 
ETM_CONTEXTID_COMPARATOR_VALUE 
ETM_CONTEXTID_COMPARATOR_MASK 
ETM_ID 

Definition at line 20 of file etm.h.

◆ anonymous enum

anonymous enum
Enumerator
ETM_CTRL_POWERDOWN 
ETM_CTRL_MONITOR_CPRT 
ETM_CTRL_TRACE_DATA 
ETM_CTRL_TRACE_ADDR 
ETM_CTRL_TRACE_MASK 
ETM_PORT_4BIT 
ETM_PORT_8BIT 
ETM_PORT_16BIT 
ETM_PORT_24BIT 
ETM_PORT_32BIT 
ETM_PORT_48BIT 
ETM_PORT_64BIT 
ETM_PORT_1BIT 
ETM_PORT_2BIT 
ETM_PORT_WIDTH_MASK 
ETM_CTRL_FIFOFULL_STALL 
ETM_CTRL_BRANCH_OUTPUT 
ETM_CTRL_DBGRQ 
ETM_CTRL_ETM_PROG 
ETM_CTRL_ETMEN 
ETM_CTRL_CYCLE_ACCURATE 
ETM_PORT_FULL_CLOCK 
ETM_PORT_HALF_CLOCK 
ETM_PORT_CLOCK_MASK 
ETM_CTRL_CONTEXTID_NONE 
ETM_CTRL_CONTEXTID_8 
ETM_CTRL_CONTEXTID_16 
ETM_CTRL_CONTEXTID_32 
ETM_CTRL_CONTEXTID_MASK 
ETM_PORT_NORMAL 
ETM_PORT_MUXED 
ETM_PORT_DEMUXED 
ETM_PORT_MODE_MASK 

Definition at line 73 of file etm.h.

◆ anonymous enum

anonymous enum
Enumerator
ETMV1_TRACESYNC_CYCLE 
ETMV1_TRIGGER_CYCLE 

Definition at line 135 of file etm.h.

◆ etmv1_branch_reason_t

Enumerator
BR_NORMAL 
BR_ENABLE 
BR_RESTART 
BR_NODEBUG 
BR_PERIOD 
BR_RSVD5 
BR_RSVD6 
BR_RSVD7 

Definition at line 190 of file etm.h.

◆ etmv1_pipestat_t

Enumerator
STAT_IE 
STAT_ID 
STAT_IN 
STAT_WT 
STAT_BE 
STAT_BD 
STAT_TR 
STAT_TD 

Definition at line 178 of file etm.h.

Function Documentation

◆ etm_build_reg_cache()

◆ etm_setup()

Variable Documentation

◆ etm_command_handlers

const struct command_registration etm_command_handlers[]
extern

Definition at line 1950 of file etm.c.