X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Ftarget%2Farm920t.c;h=98bd12f56b07b4e4d7f9f89a8a847b4756760c84;hb=1304b27d2accf7a761ff3b0c12fd5332b3c0c4da;hp=41d64733693188d9320ec8ed16a84b3f7065987a;hpb=08d4411b59dd8bd0e7d8009003b71d23acbf6eee;p=openocd.git diff --git a/src/target/arm920t.c b/src/target/arm920t.c index 41d6473369..98bd12f56b 100644 --- a/src/target/arm920t.c +++ b/src/target/arm920t.c @@ -740,6 +740,17 @@ int arm920t_write_memory(struct target *target, uint32_t address, return ERROR_OK; } +int arm920t_write_memory_opt(struct target *target, uint32_t address, + uint32_t size, uint32_t count, const uint8_t *buffer) +{ + struct arm7_9_common *arm7_9 = target_to_arm7_9(target); + + if (size == 4 && count > 32 && arm7_9->bulk_write_memory) + return arm7_9->bulk_write_memory(target, address, count, buffer); + else + return arm920t_write_memory(target, address, size, count, buffer); +} + /* EXPORTED to FA256 */ int arm920t_soft_reset_halt(struct target *target) { @@ -1697,14 +1708,12 @@ struct target_type arm920t_target = { .get_gdb_reg_list = arm_get_gdb_reg_list, .read_memory = arm920t_read_memory, - .write_memory = arm920t_write_memory, + .write_memory = arm920t_write_memory_opt, .read_phys_memory = arm920t_read_phys_memory, .write_phys_memory = arm920t_write_phys_memory, .mmu = arm920_mmu, .virt2phys = arm920_virt2phys, - .bulk_write_memory = arm7_9_bulk_write_memory, - .checksum_memory = arm_checksum_memory, .blank_check_memory = arm_blank_check_memory,