Commit a0858bfe authored by Øyvind Harboe's avatar Øyvind Harboe
Browse files

cfi: use ARM32 machine code on all CPUs but Cortex M3

ARM11 broke with aa61a3b3

as the code only checked for arm 7/9.

CFI probably needs work for non-ARM targets but perhaps
not adding working area memory to e.g. MIPS will give
the default slow CFI support.
Signed-off-by: default avatarØyvind Harboe <>
parent 4592506b
......@@ -1651,17 +1651,13 @@ static int cfi_spansion_write_block(struct flash_bank *bank, uint8_t *buffer,
armv4_5_info.core_mode = ARMV7M_MODE_HANDLER;
armv4_5_info.core_state = ARM_STATE_ARM;
else if (is_arm7_9(target_to_arm7_9(target)))
/* All other ARM CPUs have 32 bit instructions */
armv4_5_info.common_magic = ARM_COMMON_MAGIC;
armv4_5_info.core_mode = ARM_MODE_SVC;
armv4_5_info.core_state = ARM_STATE_ARM;
/* fallback to slow writes */
int target_code_size = 0;
const uint32_t *target_code_src = NULL;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment