OpenOCD
|
Go to the source code of this file.
Macros | |
#define | ARM926EJS_CP15_ADDR(opcode_1, opcode_2, crn, crm) ((opcode_1 << 11) | (opcode_2 << 8) | (crn << 4) | (crm << 0)) |
Functions | |
int | arm926ejs_arch_state (struct target *target) |
Logs summary of ARM926 state for a halted target. More... | |
static int | arm926ejs_cp15_read (struct target *target, uint32_t op1, uint32_t op2, uint32_t crn, uint32_t crm, uint32_t *value) |
static int | arm926ejs_cp15_write (struct target *target, uint32_t op1, uint32_t op2, uint32_t crn, uint32_t crm, uint32_t value) |
static void | arm926ejs_deinit_target (struct target *target) |
static int | arm926ejs_disable_mmu_caches (struct target *target, int mmu, int d_u_cache, int i_cache) |
static int | arm926ejs_enable_mmu_caches (struct target *target, int mmu, int d_u_cache, int i_cache) |
static int | arm926ejs_examine_debug_reason (struct target *target) |
static int | arm926ejs_get_ttb (struct target *target, uint32_t *result) |
int | arm926ejs_init_arch_info (struct target *target, struct arm926ejs_common *arm926ejs, struct jtag_tap *tap) |
static int | arm926ejs_mcr (struct target *target, int cpnum, uint32_t op1, uint32_t op2, uint32_t crn, uint32_t crm, uint32_t value) |
static int | arm926ejs_mmu (struct target *target, int *enabled) |
static int | arm926ejs_mrc (struct target *target, int cpnum, uint32_t op1, uint32_t op2, uint32_t crn, uint32_t crm, uint32_t *value) |
static int | arm926ejs_post_debug_entry (struct target *target) |
static void | arm926ejs_pre_restore_context (struct target *target) |
static int | arm926ejs_read_phys_memory (struct target *target, target_addr_t address, uint32_t size, uint32_t count, uint8_t *buffer) |
int | arm926ejs_soft_reset_halt (struct target *target) |
static int | arm926ejs_target_create (struct target *target, Jim_Interp *interp) |
static int | arm926ejs_verify_pointer (struct command_invocation *cmd, struct arm926ejs_common *arm926) |
static int | arm926ejs_virt2phys (struct target *target, target_addr_t virtual, target_addr_t *physical) |
int | arm926ejs_write_memory (struct target *target, target_addr_t address, uint32_t size, uint32_t count, const uint8_t *buffer) |
Writes a buffer, in the specified word size, with current MMU settings. More... | |
static int | arm926ejs_write_phys_memory (struct target *target, target_addr_t address, uint32_t size, uint32_t count, const uint8_t *buffer) |
COMMAND_HANDLER (arm926ejs_handle_cache_info_command) | |
Variables | |
static const char | arm926_not [] = "target is not an ARM926" |
const struct command_registration | arm926ejs_command_handlers [] |
static const struct command_registration | arm926ejs_exec_command_handlers [] |
struct target_type | arm926ejs_target |
Holds methods for ARM926 targets. More... | |
#define ARM926EJS_CP15_ADDR | ( | opcode_1, | |
opcode_2, | |||
crn, | |||
crm | |||
) | ((opcode_1 << 11) | (opcode_2 << 8) | (crn << 4) | (crm << 0)) |
Definition at line 38 of file arm926ejs.c.
int arm926ejs_arch_state | ( | struct target * | target | ) |
Logs summary of ARM926 state for a halted target.
Definition at line 504 of file arm926ejs.c.
References arm926_not, ARM926EJS_COMMON_MAGIC, arm_arch_state(), armv4_5_mmu_common::armv4_5_cache, arm926ejs_common::armv4_5_mmu, arm926ejs_common::common_magic, armv4_5_cache_common::d_u_cache_enabled, ERROR_OK, ERROR_TARGET_INVALID, armv4_5_cache_common::i_cache_enabled, LOG_ERROR, LOG_USER, armv4_5_mmu_common::mmu_enabled, state, and target_to_arm926().
|
static |
Definition at line 40 of file arm926ejs.c.
References ARM926EJS_CP15_ADDR, arm_jtag_scann(), arm_jtag_set_instr(), arm_le_to_h_u32(), buf_get_u32(), buf_set_u32(), ERROR_FAIL, ERROR_OK, scan_field::in_value, arm_jtag::intest_instr, jtag_add_callback(), jtag_add_dr_scan(), jtag_execute_queue(), arm7_9_common::jtag_info, LOG_DEBUG, LOG_ERROR, NULL, scan_field::num_bits, scan_field::out_value, arm_jtag::tap, TAP_IDLE, target_to_arm7_9(), and timeval_ms().
Referenced by arm926ejs_init_arch_info(), and arm926ejs_mrc().
|
static |
Definition at line 124 of file arm926ejs.c.
References ARM926EJS_CP15_ADDR, arm_jtag_scann(), arm_jtag_set_instr(), buf_get_u32(), buf_set_u32(), ERROR_FAIL, ERROR_OK, scan_field::in_value, arm_jtag::intest_instr, jtag_add_dr_scan(), jtag_execute_queue(), arm7_9_common::jtag_info, LOG_DEBUG, LOG_ERROR, NULL, scan_field::num_bits, scan_field::out_value, arm_jtag::tap, TAP_IDLE, target_to_arm7_9(), and timeval_ms().
Referenced by arm926ejs_init_arch_info(), and arm926ejs_mcr().
|
static |
Definition at line 715 of file arm926ejs.c.
References arm7_9_deinit(), arm_free_reg_cache(), target_to_arm(), and target_to_arm926().
|
static |
Definition at line 325 of file arm926ejs.c.
References ERROR_OK, jtag_execute_queue(), arm926ejs_common::read_cp15, target_to_arm926(), and arm926ejs_common::write_cp15.
Referenced by arm926ejs_init_arch_info(), and arm926ejs_soft_reset_halt().
|
static |
Definition at line 389 of file arm926ejs.c.
References ERROR_OK, jtag_execute_queue(), arm926ejs_common::read_cp15, target_to_arm926(), and arm926ejs_common::write_cp15.
Referenced by arm926ejs_init_arch_info().
|
static |
Definition at line 207 of file arm926ejs.c.
References buf_get_u32(), DBG_REASON_BREAKPOINT, DBG_REASON_DBGRQ, DBG_REASON_UNDEFINED, DBG_REASON_WATCHPOINT, target::debug_reason, arm7_9_common::eice_cache, EICE_DBG_STAT, embeddedice_read_reg(), ERROR_OK, jtag_execute_queue(), LOG_DEBUG, LOG_ERROR, LOG_WARNING, reg_cache::reg_list, target_to_arm7_9(), and reg::value.
Referenced by arm926ejs_init_arch_info().
|
static |
Definition at line 310 of file arm926ejs.c.
References ERROR_OK, arm926ejs_common::read_cp15, and target_to_arm926().
Referenced by arm926ejs_init_arch_info().
int arm926ejs_init_arch_info | ( | struct target * | target, |
struct arm926ejs_common * | arm926ejs, | ||
struct jtag_tap * | tap | ||
) |
Definition at line 666 of file arm926ejs.c.
References arm7_9_common::arm, arm926ejs_common::arm7_9_common, arm7_9_read_memory(), arm7_9_write_memory(), ARM926EJS_COMMON_MAGIC, arm926ejs_cp15_read(), arm926ejs_cp15_write(), arm926ejs_disable_mmu_caches(), arm926ejs_enable_mmu_caches(), arm926ejs_examine_debug_reason(), arm926ejs_get_ttb(), arm926ejs_mcr(), arm926ejs_mrc(), arm926ejs_post_debug_entry(), arm926ejs_pre_restore_context(), arm926ejs_write_memory(), arm9tdmi_init_arch_info(), arm7_9_common::arm_bkpt, armv4_5_mmu_common::armv4_5_cache, arm926ejs_common::armv4_5_mmu, ARMV5_BKPT, ARMV5_T_BKPT, arm926ejs_common::common_magic, armv4_5_cache_common::ctype, armv4_5_mmu_common::disable_mmu_caches, armv4_5_mmu_common::enable_mmu_caches, ERROR_OK, arm7_9_common::examine_debug_reason, armv4_5_mmu_common::get_ttb, armv4_5_mmu_common::has_tiny_pages, arm::mcr, armv4_5_mmu_common::mmu_enabled, arm::mrc, arm7_9_common::post_debug_entry, arm7_9_common::pre_restore_context, arm926ejs_common::read_cp15, armv4_5_mmu_common::read_memory, arm7_9_common::thumb_bkpt, arm926ejs_common::write_cp15, arm7_9_common::write_memory, and armv4_5_mmu_common::write_memory.
Referenced by arm926ejs_target_create(), and feroceon_target_create().
|
static |
Definition at line 197 of file arm926ejs.c.
References arm926ejs_cp15_write(), ERROR_FAIL, and LOG_ERROR.
Referenced by arm926ejs_init_arch_info().
|
static |
Definition at line 752 of file arm926ejs.c.
|
static |
Definition at line 114 of file arm926ejs.c.
References arm926ejs_cp15_read(), ERROR_FAIL, and LOG_ERROR.
Referenced by arm926ejs_init_arch_info().
|
static |
Definition at line 417 of file arm926ejs.c.
References armv4_5_mmu_common::armv4_5_cache, armv4_5_identify_cache(), arm926ejs_common::armv4_5_mmu, arm926ejs_common::cp15_control_reg, armv4_5_cache_common::ctype, arm926ejs_common::d_far, arm926ejs_common::d_fsr, armv4_5_cache_common::d_u_cache_enabled, ERROR_OK, armv4_5_cache_common::i_cache_enabled, arm926ejs_common::i_fsr, jtag_execute_queue(), LOG_DEBUG, armv4_5_mmu_common::mmu_enabled, arm926ejs_common::read_cp15, target_to_arm926(), and arm926ejs_common::write_cp15.
Referenced by arm926ejs_init_arch_info().
|
static |
Definition at line 473 of file arm926ejs.c.
References arm926ejs_common::d_far, arm926ejs_common::d_fsr, arm926ejs_common::i_fsr, arm926ejs_common::read_cp15, target_to_arm926(), and arm926ejs_common::write_cp15.
Referenced by arm926ejs_init_arch_info().
|
static |
Definition at line 656 of file arm926ejs.c.
References arm926ejs_common::armv4_5_mmu, armv4_5_mmu_read_physical(), buffer, count, size, and target_to_arm926().
int arm926ejs_soft_reset_halt | ( | struct target * | target | ) |
Definition at line 526 of file arm926ejs.c.
References alive_sleep(), arm7_9_common::arm, arm926ejs_disable_mmu_caches(), arm_set_cpsr(), armv4_5_mmu_common::armv4_5_cache, arm926ejs_common::armv4_5_mmu, buf_get_u32(), buf_set_u32(), arm::cpsr, armv4_5_cache_common::d_u_cache_enabled, debug_level, reg::dirty, arm7_9_common::eice_cache, EICE_DBG_STAT, EICE_DBG_STATUS_DBGACK, embeddedice_read_reg(), ERROR_OK, ERROR_TARGET_TIMEOUT, armv4_5_cache_common::i_cache_enabled, jtag_execute_queue(), keep_alive(), LOG_ERROR, armv4_5_mmu_common::mmu_enabled, arm::pc, reg_cache::reg_list, target::state, target_call_event_callbacks(), TARGET_EVENT_HALTED, target_halt(), TARGET_HALTED, target_to_arm7_9(), target_to_arm926(), timeval_ms(), reg::valid, and reg::value.
|
static |
Definition at line 705 of file arm926ejs.c.
References arm926ejs_init_arch_info(), jtag_tap::ir_capture_mask, and target::tap.
|
static |
Definition at line 493 of file arm926ejs.c.
References arm926_not, ARM926EJS_COMMON_MAGIC, cmd, command_print(), arm926ejs_common::common_magic, ERROR_OK, and ERROR_TARGET_INVALID.
Referenced by COMMAND_HANDLER().
|
static |
Definition at line 738 of file arm926ejs.c.
References arm926ejs_common::armv4_5_mmu, armv4_5_mmu_translate_va(), ERROR_OK, and target_to_arm926().
int arm926ejs_write_memory | ( | struct target * | target, |
target_addr_t | address, | ||
uint32_t | size, | ||
uint32_t | count, | ||
const uint8_t * | buffer | ||
) |
Writes a buffer, in the specified word size, with current MMU settings.
Definition at line 586 of file arm926ejs.c.
References arm7_9_write_memory(), armv4_5_mmu_common::armv4_5_cache, arm926ejs_common::armv4_5_mmu, armv4_5_mmu_write_physical(), buffer, count, armv4_5_cache_common::d_u_cache_enabled, ERROR_OK, armv4_5_cache_common::i_cache_enabled, armv4_5_mmu_common::mmu_enabled, size, target_to_arm926(), target::type, target_type::virt2phys, and arm926ejs_common::write_cp15.
Referenced by arm926ejs_init_arch_info(), and feroceon_target_create().
|
static |
Definition at line 646 of file arm926ejs.c.
References arm926ejs_common::armv4_5_mmu, armv4_5_mmu_write_physical(), buffer, count, size, and target_to_arm926().
COMMAND_HANDLER | ( | arm926ejs_handle_cache_info_command | ) |
Definition at line 725 of file arm926ejs.c.
References arm926ejs_verify_pointer(), armv4_5_mmu_common::armv4_5_cache, armv4_5_handle_cache_info_command(), arm926ejs_common::armv4_5_mmu, CMD, CMD_CTX, ERROR_OK, get_current_target(), and target_to_arm926().
|
static |
Definition at line 491 of file arm926ejs.c.
Referenced by arm926ejs_arch_state(), and arm926ejs_verify_pointer().
const struct command_registration arm926ejs_command_handlers[] |
Definition at line 752 of file arm926ejs.c.
|
static |
Definition at line 752 of file arm926ejs.c.
struct target_type arm926ejs_target |
Holds methods for ARM926 targets.
Definition at line 752 of file arm926ejs.c.