gdb_server: add debug signal reason prints
[openocd.git] / src / target / target.h
index e221351a834c9d8e0176536ce6c03254ef557352..abeb8ed511139d1875a64eceae7723178eb10fb0 100644 (file)
@@ -57,11 +57,6 @@ enum target_state {
        TARGET_DEBUG_RUNNING = 4,
 };
 
-enum nvp_assert {
-       NVP_DEASSERT,
-       NVP_ASSERT,
-};
-
 enum target_reset_mode {
        RESET_UNKNOWN = 0,
        RESET_RUN = 1,          /* reset and let target run */
@@ -193,6 +188,10 @@ struct target {
        struct list_head *smp_targets;          /* list all targets in this smp group/cluster
                                                                                 * The head of the list is shared between the
                                                                                 * cluster, thus here there is a pointer */
+       bool smp_halt_event_postponed;          /* Some SMP implementations (currently Cortex-M) stores
+                                                                                * 'halted' events and emits them after all targets of
+                                                                                * the SMP group has been polled */
+
        /* the gdb service is there in case of smp, we have only one gdb server
         * for all smp target
         * the target attached to the gdb is changing dynamically by changing
@@ -286,14 +285,14 @@ enum target_event {
 
        TARGET_EVENT_TRACE_CONFIG,
 
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x100 = 0x100, /* semihosting allows user cmds from 0x100 to 0x1ff */
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x101 = 0x101,
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x102 = 0x102,
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x103 = 0x103,
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x104 = 0x104,
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x105 = 0x105,
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x106 = 0x106,
-       TARGET_EVENT_SEMIHOSTING_USER_CMD_0x107 = 0x107,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X100 = 0x100, /* semihosting allows user cmds from 0x100 to 0x1ff */
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X101 = 0x101,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X102 = 0x102,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X103 = 0x103,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X104 = 0x104,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X105 = 0x105,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X106 = 0x106,
+       TARGET_EVENT_SEMIHOSTING_USER_CMD_0X107 = 0x107,
 };
 
 struct target_event_action {
@@ -548,7 +547,7 @@ int target_run_algorithm(struct target *target,
                int num_mem_params, struct mem_param *mem_params,
                int num_reg_params, struct reg_param *reg_param,
                target_addr_t entry_point, target_addr_t exit_point,
-               int timeout_ms, void *arch_info);
+               unsigned int timeout_ms, void *arch_info);
 
 /**
  * Starts an algorithm in the background on the @a target given.
@@ -569,7 +568,7 @@ int target_start_algorithm(struct target *target,
 int target_wait_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 exit_point, int timeout_ms,
+               target_addr_t exit_point, unsigned int timeout_ms,
                void *arch_info);
 
 /**
@@ -661,7 +660,7 @@ int target_checksum_memory(struct target *target,
 int target_blank_check_memory(struct target *target,
                struct target_memory_check_block *blocks, int num_blocks,
                uint8_t erased_value);
-int target_wait_state(struct target *target, enum target_state state, int ms);
+int target_wait_state(struct target *target, enum target_state state, unsigned int ms);
 
 /**
  * Obtain file-I/O information from target for GDB to do syscall.
@@ -804,4 +803,6 @@ extern bool get_target_reset_nag(void);
 
 #define TARGET_DEFAULT_POLLING_INTERVAL                100
 
+const char *target_debug_reason_str(enum target_debug_reason reason);
+
 #endif /* OPENOCD_TARGET_TARGET_H */

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)