Skip to content

Commit

Permalink
hosted/cmsis_dap: Fixed the nomenclature for dap_dp_raw_access
Browse files Browse the repository at this point in the history
  • Loading branch information
dragonmux committed Jan 14, 2024
1 parent 9ceb775 commit 0e3b50d
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/platforms/hosted/cmsis_dap.c
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ void dap_dp_abort(adiv5_debug_port_s *const target_dp, const uint32_t abort)
dap_write_reg(target_dp, ADIV5_DP_ABORT, abort);
}

uint32_t dap_dp_low_access(
uint32_t dap_dp_raw_access(
adiv5_debug_port_s *const target_dp, const uint8_t rnw, const uint16_t addr, const uint32_t value)
{
const bool APnDP = addr & ADIV5_APnDP;
Expand All @@ -401,11 +401,11 @@ uint32_t dap_dp_low_access(

uint32_t dap_dp_read_reg(adiv5_debug_port_s *const target_dp, const uint16_t addr)
{
uint32_t result = dap_dp_low_access(target_dp, ADIV5_LOW_READ, addr, 0);
uint32_t result = dap_dp_raw_access(target_dp, ADIV5_LOW_READ, addr, 0);
if (target_dp->fault == DAP_TRANSFER_NO_RESPONSE) {
DEBUG_WARN("Recovering and re-trying access\n");
target_dp->error(target_dp, true);
result = dap_dp_low_access(target_dp, ADIV5_LOW_READ, addr, 0);
result = dap_dp_raw_access(target_dp, ADIV5_LOW_READ, addr, 0);
}
DEBUG_PROBE("dp_read %04x %08" PRIx32 "\n", addr, result);
return result;
Expand Down
2 changes: 1 addition & 1 deletion src/platforms/hosted/dap.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ bool dap_run_cmd(const void *request_data, size_t request_length, void *response
bool dap_jtag_configure(void);

void dap_dp_abort(adiv5_debug_port_s *target_dp, uint32_t abort);
uint32_t dap_dp_low_access(adiv5_debug_port_s *target_dp, uint8_t rnw, uint16_t addr, uint32_t value);
uint32_t dap_dp_raw_access(adiv5_debug_port_s *target_dp, uint8_t rnw, uint16_t addr, uint32_t value);
uint32_t dap_dp_read_reg(adiv5_debug_port_s *target_dp, uint16_t addr);

#endif /* PLATFORMS_HOSTED_DAP_H */
2 changes: 1 addition & 1 deletion src/platforms/hosted/dap_jtag.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ void dap_jtag_dp_init(adiv5_debug_port_s *target_dp)
if (!dap_jtag_configure())
return;
target_dp->dp_read = dap_dp_read_reg;
target_dp->low_access = dap_dp_low_access;
target_dp->low_access = dap_dp_raw_access;
target_dp->abort = dap_dp_abort;
}

Expand Down
2 changes: 1 addition & 1 deletion src/platforms/hosted/dap_swd.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ bool dap_swd_init(adiv5_debug_port_s *target_dp)
/* Set up the accelerated SWD functions for basic target operations */
target_dp->read_no_check = dap_read_reg_no_check;
target_dp->dp_read = dap_dp_read_reg;
target_dp->low_access = dap_dp_low_access;
target_dp->low_access = dap_dp_raw_access;
target_dp->abort = dap_dp_abort;
return true;
}
Expand Down

0 comments on commit 0e3b50d

Please sign in to comment.