Documentation: fix warning "unbalanced square brackets"
[openocd.git] / src / target / riscv / riscv.c
index 865abd08021aa8e9295eace4954db9faed1ecb41..9cd4922d20d7f0974d1d72410f7bfb663111eb70 100644 (file)
@@ -1744,7 +1744,7 @@ static int riscv_write_memory(struct target *target, target_addr_t address,
        return tt->write_memory(target, address, size, count, buffer);
 }
 
-static const char *riscv_get_gdb_arch(struct target *target)
+static const char *riscv_get_gdb_arch(const struct target *target)
 {
        switch (riscv_xlen(target)) {
                case 32:
@@ -1830,7 +1830,7 @@ static int riscv_arch_state(struct target *target)
 static int riscv_run_algorithm(struct target *target, int num_mem_params,
                struct mem_param *mem_params, int num_reg_params,
                struct reg_param *reg_params, target_addr_t entry_point,
-               target_addr_t exit_point, int timeout_ms, void *arch_info)
+               target_addr_t exit_point, unsigned int timeout_ms, void *arch_info)
 {
        RISCV_INFO(info);
 
@@ -1840,7 +1840,7 @@ static int riscv_run_algorithm(struct target *target, int num_mem_params,
        }
 
        if (target->state != TARGET_HALTED) {
-               LOG_WARNING("target not halted");
+               LOG_TARGET_ERROR(target, "not halted (run target algo)");
                return ERROR_TARGET_NOT_HALTED;
        }
 
@@ -2052,7 +2052,7 @@ static int riscv_checksum_memory(struct target *target,
        buf_set_u64(reg_params[1].value, 0, xlen, count);
 
        /* 20 second timeout/megabyte */
-       int timeout = 20000 * (1 + (count / (1024 * 1024)));
+       unsigned int timeout = 20000 * (1 + (count / (1024 * 1024)));
 
        retval = target_run_algorithm(target, 0, NULL, 2, reg_params,
                        crc_algorithm->address,
@@ -3851,7 +3851,7 @@ int riscv_init_registers(struct target *target)
                .type = REG_TYPE_ARCH_DEFINED,
                .id = "FPU_FD",
                .type_class = REG_TYPE_CLASS_UNION,
-               .reg_type_union = &single_double_union
+               { .reg_type_union = &single_double_union }
        };
        static struct reg_data_type type_uint8 = { .type = REG_TYPE_UINT8, .id = "uint8" };
        static struct reg_data_type type_uint16 = { .type = REG_TYPE_UINT16, .id = "uint16" };

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)