Add null pointer check before right shift for bscan tunneling.
Change-Id: I5d4764c777f33d48705b3e5273eb840c13cfbfb7 Signed-off-by: eolson <erin.olson@seagate.com>
This commit is contained in:
parent
a45589d60a
commit
9d23d3774a
|
@ -115,9 +115,11 @@ int riscv_batch_run(struct riscv_batch *batch)
|
|||
|
||||
if (bscan_tunnel_ir_width != 0) {
|
||||
/* need to right-shift "in" by one bit, because of clock skew between BSCAN TAP and DM TAP */
|
||||
for (size_t i = 0; i < batch->used_scans; ++i)
|
||||
for (size_t i = 0; i < batch->used_scans; ++i) {
|
||||
if ((batch->fields + i)->in_value)
|
||||
buffer_shr((batch->fields + i)->in_value, DMI_SCAN_BUF_SIZE, 1);
|
||||
}
|
||||
}
|
||||
|
||||
for (size_t i = 0; i < batch->used_scans; ++i)
|
||||
dump_field(batch->idle_count, batch->fields + i);
|
||||
|
|
Loading…
Reference in New Issue