From ee3af96a736139b71678a0e590865f9ffafc2f35 Mon Sep 17 00:00:00 2001 From: Gareth McMullin Date: Sun, 15 Mar 2015 14:31:57 -0700 Subject: Consolidate target_mem_read* and target_mem_write* methods. There are now only mem_read and mem_write, that must handle all alignments. These methods return void, errors must be checked with target_check_error.--- src/stm32f4.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/stm32f4.c') diff --git a/src/stm32f4.c b/src/stm32f4.c index fac097a..58d1328 100644 --- a/src/stm32f4.c +++ b/src/stm32f4.c @@ -253,8 +253,8 @@ static int stm32f4_flash_write(struct target_s *target, uint32_t dest, memcpy((uint8_t *)&data[2] + offset, src, len); /* Write stub and data to target ram and set PC */ - target_mem_write_words(target, 0x20000000, (void*)stm32f4_flash_write_stub, 0x30); - target_mem_write_words(target, 0x20000030, data, sizeof(data)); + target_mem_write(target, 0x20000000, stm32f4_flash_write_stub, 0x30); + target_mem_write(target, 0x20000030, data, sizeof(data)); target_pc_write(target, 0x20000000); if(target_check_error(target)) return -1; -- cgit v1.2.3