jtag: fix some minor typo
[openocd.git] / src / jtag / core.c
index 03a26bec21af6894ee347935931f4d9933bb19cc..2166374cc74c732de6c22965ebcf5e6279c0f47d 100644 (file)
@@ -35,6 +35,7 @@
 #include "interface.h"
 #include <transport/transport.h>
 #include <helper/jep106.h>
+#include "helper/system.h"
 
 #ifdef HAVE_STRINGS_H
 #include <strings.h>
@@ -44,6 +45,9 @@
 #include "svf/svf.h"
 #include "xsvf/xsvf.h"
 
+/* ipdbg are utilities to debug IP-cores. It uses JTAG for transport. */
+#include "server/ipdbg.h"
+
 /** The number of JTAG queue flushes (for profiling and debugging purposes). */
 static int jtag_flush_queue_count;
 
@@ -209,7 +213,7 @@ unsigned jtag_tap_count_enabled(void)
 }
 
 /** Append a new TAP to the chain of all taps. */
-void jtag_tap_add(struct jtag_tap *t)
+static void jtag_tap_add(struct jtag_tap *t)
 {
        unsigned jtag_num_taps = 0;
 
@@ -426,7 +430,6 @@ static void jtag_add_scan_check(struct jtag_tap *active, void (*jtag_add_scan)(
 
        for (int i = 0; i < in_num_fields; i++) {
                if ((in_fields[i].check_value != NULL) && (in_fields[i].in_value != NULL)) {
-                       /* this is synchronous for a minidriver */
                        jtag_add_callback4(jtag_check_value_mask_callback,
                                (jtag_callback_data_t)in_fields[i].in_value,
                                (jtag_callback_data_t)in_fields[i].check_value,
@@ -487,7 +490,7 @@ void jtag_add_tlr(void)
 
 /**
  * If supported by the underlying adapter, this clocks a raw bit sequence
- * onto TMS for switching betwen JTAG and SWD modes.
+ * onto TMS for switching between JTAG and SWD modes.
  *
  * DO NOT use this to bypass the integrity checks and logging provided
  * by the jtag_add_pathmove() and jtag_add_statemove() calls.
@@ -953,12 +956,6 @@ int default_interface_jtag_execute_queue(void)
 
        int result = jtag->jtag_ops->execute_queue();
 
-#if !BUILD_ZY1000
-       /* Only build this if we use a regular driver with a command queue.
-        * Otherwise jtag_command_queue won't be found at compile/link time. Its
-        * definition is in jtag/commands.c, which is only built/linked by
-        * jtag/Makefile.am if MINIDRIVER_DUMMY || !MINIDRIVER, but those variables
-        * aren't accessible here. */
        struct jtag_command *cmd = jtag_command_queue;
        while (debug_level >= LOG_LVL_DEBUG_IO && cmd) {
                switch (cmd->type) {
@@ -1017,7 +1014,6 @@ int default_interface_jtag_execute_queue(void)
                }
                cmd = cmd->next;
        }
-#endif
 
        return result;
 }
@@ -1347,7 +1343,7 @@ static int jtag_validate_ircapture(void)
        int chain_pos = 0;
        int retval;
 
-       /* when autoprobing, accomodate huge IR lengths */
+       /* when autoprobing, accommodate huge IR lengths */
        for (tap = NULL, total_ir_length = 0;
                        (tap = jtag_tap_next_enabled(tap)) != NULL;
                        total_ir_length += tap->ir_length) {
@@ -1982,7 +1978,12 @@ static int jtag_select(struct command_context *ctx)
        if (retval != ERROR_OK)
                return retval;
 
-       return xsvf_register_commands(ctx);
+       retval = xsvf_register_commands(ctx);
+
+       if (retval != ERROR_OK)
+               return retval;
+
+       return ipdbg_register_commands(ctx);
 }
 
 static struct transport jtag_transport = {

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)