From fbe8cf72a5e6c80fed5fba8754d790ca63ad2b65 Mon Sep 17 00:00:00 2001 From: zwelch Date: Sun, 31 May 2009 09:38:20 +0000 Subject: Add target_run_algorithm wrapper: - replaces all calls to target->type->run_algorithm. - add documentation in target_s to warn not to invoke callback directly. git-svn-id: svn://svn.berlios.de/openocd/trunk@1961 b42882b7-edfa-0310-969c-e2dbd0fdcd60 --- src/flash/pic32mx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/flash/pic32mx.c') diff --git a/src/flash/pic32mx.c b/src/flash/pic32mx.c index 2a5ce641..b45902cd 100644 --- a/src/flash/pic32mx.c +++ b/src/flash/pic32mx.c @@ -419,7 +419,7 @@ static int pic32mx_write_block(struct flash_bank_s *bank, u8 *buffer, u32 offset buf_set_u32(reg_params[1].value, 0, 32, address); buf_set_u32(reg_params[2].value, 0, 32, buffer_size/4); - if ((retval = target->type->run_algorithm(target, 0, NULL, 4, reg_params, pic32mx_info->write_algorithm->address, \ + if ((retval = target_run_algorithm(target, 0, NULL, 4, reg_params, pic32mx_info->write_algorithm->address, \ pic32mx_info->write_algorithm->address + (sizeof(pic32mx_flash_write_code) - 10), 10000, &armv7m_info)) != ERROR_OK) { LOG_ERROR("error executing pic32mx flash write algorithm"); -- cgit v1.2.3