aboutsummaryrefslogtreecommitdiff
path: root/src/flash
diff options
context:
space:
mode:
authorTomas Vanek <vanekt@fbl.cz>2020-05-17 08:17:25 +0200
committerAntonio Borneo <borneo.antonio@gmail.com>2020-05-24 21:25:48 +0100
commit9a5af06f821e2c61adbf2b5cac720ba8d608a014 (patch)
tree5e72a62b27cb34ae0529ba2d9876bae6312d710e /src/flash
parentec30634c13e9a311d597b8860a4671d91cfb34a6 (diff)
downloadriscv-openocd-9a5af06f821e2c61adbf2b5cac720ba8d608a014.zip
riscv-openocd-9a5af06f821e2c61adbf2b5cac720ba8d608a014.tar.gz
riscv-openocd-9a5af06f821e2c61adbf2b5cac720ba8d608a014.tar.bz2
flash/nor/jtagspi: propagate error from jtag_execute_queue()
Change-Id: Ib985bdf3d60345a1e701f9cc98f89a47ff74d3e2 Signed-off-by: Tomas Vanek <vanekt@fbl.cz> Reviewed-on: http://openocd.zylin.com/5684 Tested-by: jenkins Reviewed-by: Tarek BOCHKATI <tarek.bouchkati@gmail.com> Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Diffstat (limited to 'src/flash')
-rw-r--r--src/flash/nor/jtagspi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/flash/nor/jtagspi.c b/src/flash/nor/jtagspi.c
index 73b1c7a..d841579 100644
--- a/src/flash/nor/jtagspi.c
+++ b/src/flash/nor/jtagspi.c
@@ -153,12 +153,12 @@ static int jtagspi_cmd(struct flash_bank *bank, uint8_t cmd,
jtagspi_set_ir(bank);
/* passing from an IR scan to SHIFT-DR clears BYPASS registers */
jtag_add_dr_scan(info->tap, n, fields, TAP_IDLE);
- jtag_execute_queue();
+ int retval = jtag_execute_queue();
if (is_read)
flip_u8(data_buf, data, lenb);
free(data_buf);
- return ERROR_OK;
+ return retval;
}
static int jtagspi_probe(struct flash_bank *bank)