drivers/jtag_dpi: Group adapter commands 94/6394/3
authorMarc Schink <dev@zapb.de>
Fri, 30 Jul 2021 16:24:03 +0000 (18:24 +0200)
committerAntonio Borneo <borneo.antonio@gmail.com>
Sat, 14 Aug 2021 12:34:49 +0000 (13:34 +0100)
Use a command group 'jtag_dpi' with subcommands instead of individual
commands with 'jtag_dpi_' prefix.

The old commands are still available for backward compatibility but
marked as deprecated.

Change-Id: I19271546235a3c6737f975976a0bf0a2f66cbbe7
Signed-off-by: Marc Schink <dev@zapb.de>
Reviewed-on: http://openocd.zylin.com/6394
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
doc/openocd.texi
src/jtag/drivers/jtag_dpi.c
src/jtag/startup.tcl

index eb45acc396e1df17198821d4b97e482d7baad20e..aec6bbe4fc6c684e946616bfebfe034ab8ded812 100644 (file)
@@ -3321,11 +3321,11 @@ SystemVerilog Direct Programming Interface (DPI) compatible driver for
 JTAG devices in emulation. The driver acts as a client for the SystemVerilog
 DPI server interface.
 
-@deffn {Config Command} {jtag_dpi_set_port} port
+@deffn {Config Command} {jtag_dpi set_port} port
 Specifies the TCP/IP port number of the SystemVerilog DPI server interface.
 @end deffn
 
-@deffn {Config Command} {jtag_dpi_set_address} address
+@deffn {Config Command} {jtag_dpi set_address} address
 Specifies the TCP/IP address of the SystemVerilog DPI server interface.
 @end deffn
 @end deffn
index 73746d6d227bba3f3f1070e54d2e71a72fb5506a..016ff55366a383e51fb540acef2e44c7c2c87bc6 100644 (file)
@@ -373,16 +373,16 @@ COMMAND_HANDLER(jtag_dpi_set_address)
        return ERROR_OK;
 }
 
-static const struct command_registration jtag_dpi_command_handlers[] = {
+static const struct command_registration jtag_dpi_subcommand_handlers[] = {
        {
-               .name = "jtag_dpi_set_port",
+               .name = "set_port",
                .handler = &jtag_dpi_set_port,
                .mode = COMMAND_CONFIG,
                .help = "set the port of the DPI server",
                .usage = "[port]",
        },
        {
-               .name = "jtag_dpi_set_address",
+               .name = "set_address",
                .handler = &jtag_dpi_set_address,
                .mode = COMMAND_CONFIG,
                .help = "set the address of the DPI server",
@@ -391,6 +391,17 @@ static const struct command_registration jtag_dpi_command_handlers[] = {
        COMMAND_REGISTRATION_DONE
 };
 
+static const struct command_registration jtag_dpi_command_handlers[] = {
+       {
+               .name = "jtag_dpi",
+               .mode = COMMAND_ANY,
+               .help = "perform jtag_dpi management",
+               .chain = jtag_dpi_subcommand_handlers,
+               .usage = "",
+       },
+       COMMAND_REGISTRATION_DONE
+};
+
 static struct jtag_interface jtag_dpi_interface = {
        .supported = DEBUG_CAP_TMS_SEQ,
        .execute_queue = jtag_dpi_execute_queue,
index 92d8c8de45e987ba8f66ea3a03c361b034efff93..263cde2551db797b68f275e5ffdb03bd912c1a57 100644 (file)
@@ -309,6 +309,18 @@ proc parport_toggling_time args {
        eval parport toggling_time $args
 }
 
+lappend _telnet_autocomplete_skip jtag_dpi_set_port
+proc jtag_dpi_set_port args {
+       echo "DEPRECATED! use 'jtag_dpi set_port' not 'jtag_dpi_set_port'"
+       eval jtag_dpi set_port $args
+}
+
+lappend _telnet_autocomplete_skip jtag_dpi_set_address
+proc jtag_dpi_set_address args {
+       echo "DEPRECATED! use 'jtag_dpi set_address' not 'jtag_dpi_set_address'"
+       eval jtag_dpi set_address $args
+}
+
 lappend _telnet_autocomplete_skip presto_serial
 proc presto_serial args {
        echo "DEPRECATED! use 'presto serial' not 'presto_serial'"

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)