aboutsummaryrefslogtreecommitdiff
path: root/src/xsvf
diff options
context:
space:
mode:
authoroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2009-05-08 07:28:00 +0000
committeroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>2009-05-08 07:28:00 +0000
commitbf4da345ecb678a8f608a3380bf367d1e15b92c2 (patch)
tree4481c0ea8cc1bfa8e37228840bce4b8152455a9d /src/xsvf
parentfe629829f498cde66697a4060618d99a39fa277c (diff)
downloadriscv-openocd-bf4da345ecb678a8f608a3380bf367d1e15b92c2.zip
riscv-openocd-bf4da345ecb678a8f608a3380bf367d1e15b92c2.tar.gz
riscv-openocd-bf4da345ecb678a8f608a3380bf367d1e15b92c2.tar.bz2
retire jtag_set_check_value
git-svn-id: svn://svn.berlios.de/openocd/trunk@1668 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src/xsvf')
-rw-r--r--src/xsvf/xsvf.c25
1 files changed, 15 insertions, 10 deletions
diff --git a/src/xsvf/xsvf.c b/src/xsvf/xsvf.c
index 24a14de..0e3152d 100644
--- a/src/xsvf/xsvf.c
+++ b/src/xsvf/xsvf.c
@@ -501,16 +501,18 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
field.tap = tap;
field.num_bits = xsdrsize;
field.out_value = dr_out_buf;
-
- field.in_value = NULL;
-
- jtag_set_check_value(&field, dr_in_buf, dr_in_mask, NULL);
+ field.in_value = calloc(CEIL(field.num_bits, 8), 1);
if (tap == NULL)
jtag_add_plain_dr_scan(1, &field, TAP_DRPAUSE);
else
jtag_add_dr_scan(1, &field, TAP_DRPAUSE);
+ jtag_check_value_mask(&field, dr_in_buf, dr_in_mask);
+
+ free(field.in_value);
+
+
/* LOG_DEBUG("FLUSHING QUEUE"); */
result = jtag_execute_queue();
if (result == ERROR_OK)
@@ -713,10 +715,10 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
field.tap = tap;
field.num_bits = bitcount;
field.out_value = ir_buf;
-
+
field.in_value = NULL;
-
-
+
+
field.in_handler = NULL;
if (tap == NULL)
@@ -944,18 +946,21 @@ static int handle_xsvf_command(struct command_context_s *cmd_ctx, char *cmd, cha
field.tap = tap;
field.num_bits = xsdrsize;
field.out_value = dr_out_buf;
-
- field.in_value = NULL;
+ field.in_value = calloc(CEIL(field.num_bits, 8), 1);
if (attempt > 0 && verbose)
LOG_USER("LSDR retry %d", attempt);
- jtag_set_check_value(&field, dr_in_buf, dr_in_mask, NULL);
if (tap == NULL)
jtag_add_plain_dr_scan(1, &field, TAP_DRPAUSE);
else
jtag_add_dr_scan(1, &field, TAP_DRPAUSE);
+ jtag_check_value_mask(&field, dr_in_buf, dr_in_mask);
+
+ free(field.in_value);
+
+
/* LOG_DEBUG("FLUSHING QUEUE"); */
result = jtag_execute_queue();
if(result == ERROR_OK)