forked from auracaster/openocd
Add target_read_memory wrapper:
- replaces all calls to target->type->read_memory. - add documentation in target_s to warn not to invoke callback directly. git-svn-id: svn://svn.berlios.de/openocd/trunk@1959 b42882b7-edfa-0310-969c-e2dbd0fdcd60
This commit is contained in:
@@ -2187,7 +2187,7 @@ int xscale_set_breakpoint(struct target_s *target, breakpoint_t *breakpoint)
|
||||
if (breakpoint->length == 4)
|
||||
{
|
||||
/* keep the original instruction in target endianness */
|
||||
if((retval = target->type->read_memory(target, breakpoint->address, 4, 1, breakpoint->orig_instr)) != ERROR_OK)
|
||||
if((retval = target_read_memory(target, breakpoint->address, 4, 1, breakpoint->orig_instr)) != ERROR_OK)
|
||||
{
|
||||
return retval;
|
||||
}
|
||||
@@ -2200,7 +2200,7 @@ int xscale_set_breakpoint(struct target_s *target, breakpoint_t *breakpoint)
|
||||
else
|
||||
{
|
||||
/* keep the original instruction in target endianness */
|
||||
if((retval = target->type->read_memory(target, breakpoint->address, 2, 1, breakpoint->orig_instr)) != ERROR_OK)
|
||||
if((retval = target_read_memory(target, breakpoint->address, 2, 1, breakpoint->orig_instr)) != ERROR_OK)
|
||||
{
|
||||
return retval;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user