diff options
author | Evan Hunter <ehunter@broadcom.com> | 2012-10-31 17:51:45 +1100 |
---|---|---|
committer | Antonio Borneo <borneo.antonio@gmail.com> | 2024-02-11 23:12:03 +0000 |
commit | 847f1209d644fb1db45f7a385d9592eba76ab688 (patch) | |
tree | b36cbc607cf80cc761c4cecca79d20c0430b7e48 /src/jtag/commands.c | |
parent | c6e7e48b053c281ef4a9dd50f2d94fa12184a956 (diff) | |
download | riscv-openocd-847f1209d644fb1db45f7a385d9592eba76ab688.zip riscv-openocd-847f1209d644fb1db45f7a385d9592eba76ab688.tar.gz riscv-openocd-847f1209d644fb1db45f7a385d9592eba76ab688.tar.bz2 |
jtag interfaces: Reduce usage of global for jtag queue
Makes driver interface slightly more flexible.
Change-Id: I2c7f5cb6d014e94a0e6122cbe2f4002c77fbabb9
Signed-off-by: Evan Hunter <ehunter@broadcom.com>
Signed-off-by: David Ryskalczyk <david.rysk@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/945
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Tested-by: jenkins
Diffstat (limited to 'src/jtag/commands.c')
-rw-r--r-- | src/jtag/commands.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/jtag/commands.c b/src/jtag/commands.c index 43cda8a..c36c219 100644 --- a/src/jtag/commands.c +++ b/src/jtag/commands.c @@ -33,7 +33,7 @@ struct cmd_queue_page { static struct cmd_queue_page *cmd_queue_pages; static struct cmd_queue_page *cmd_queue_pages_tail; -struct jtag_command *jtag_command_queue; +static struct jtag_command *jtag_command_queue; static struct jtag_command **next_command_pointer = &jtag_command_queue; void jtag_queue_command(struct jtag_command *cmd) @@ -147,6 +147,11 @@ void jtag_command_queue_reset(void) next_command_pointer = &jtag_command_queue; } +struct jtag_command *jtag_command_queue_get(void) +{ + return jtag_command_queue; +} + /** * Copy a struct scan_field for insertion into the queue. * |