cfi: use ARM32 machine code on all CPUs but Cortex M3
authorØyvind Harboe <oyvind.harboe@zylin.com>
Mon, 31 Jan 2011 09:30:48 +0000 (10:30 +0100)
committerØyvind Harboe <oyvind.harboe@zylin.com>
Mon, 31 Jan 2011 09:30:48 +0000 (10:30 +0100)
ARM11 broke with aa61a3b3d8b6acad19050987835ec05f3d298bdb
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: Øyvind Harboe <oyvind.harboe@zylin.com>
src/flash/nor/cfi.c

index f462d72100c7c7907b9cc88cde90e45f6c58989c..1fa3f2da602a7512e21a4ac3ab7503af98b5f6a1 100644 (file)
@@ -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)))
+       else
        {
+               /* 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;
        }
-       else
-       {
-               /* fallback to slow writes */
-               return ERROR_TARGET_RESOURCE_NOT_AVAILABLE;
-       }
 
        int target_code_size = 0;
        const uint32_t *target_code_src = NULL;

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)