Age | Commit message (Collapse) | Author | Files | Lines |
|
Change-Id: I6e7c0866291dd87946a4fd49d9bfe4cddefb3957
|
|
Conflicts:
src/target/riscv/riscv-013.c
src/target/riscv/riscv.c
Change-Id: I65bdb4d28c91e9022ce811de976c9bf474a0b590
|
|
Conflicts:
doc/openocd.texi
src/jtag/aice/aice_pipe.c
src/jtag/aice/aice_usb.c
src/rtos/FreeRTOS.c
src/rtos/hwthread.c
src/rtos/rtos_standard_stackings.c
src/target/riscv/riscv.c
Change-Id: I0c6228c499d60274325be895fbcd8007ed1699bc
|
|
Change-Id: I7537c122d581ec1848a1e7902874506e0bbb6e31
Signed-off-by: Tim Newsome <tim@sifive.com>
|
|
This includes
https://sourceforge.net/p/openocd/mailman/message/37710818/, which
should fix #814.
Conflicts:
.travis.yml
contrib/loaders/flash/stm32/stm32f1x.S
contrib/loaders/flash/stm32/stm32f2x.S
doc/openocd.texi
src/rtos/FreeRTOS.c
src/server/gdb_server.c
src/target/riscv/riscv-013.c
src/target/riscv/riscv.c
src/target/riscv/riscv.h
src/target/riscv/riscv_semihosting.c
tcl/target/esp_common.cfg
tcl/target/gd32vf103.cfg
tools/scripts/checkpatch.pl
Change-Id: I1986c13298ca0dafbe3aecaf1b0b35626525e4eb
|
|
This probably crept in when merging in upstream in the past.
Change-Id: Iccce4515b6b5d4a90773f6d432754b065fb240bb
Signed-off-by: Tim Newsome <tim@sifive.com>
|
|
Conflicts:
doc/openocd.texi
src/target/riscv/riscv-013.c
src/target/riscv/riscv.c
Change-Id: I8cd557a10c3d5beeaed05ecc05d4c325a9ee7e70
|
|
Polling the target makes no harm during PSoC 4 flash write in the current
OpenOCD code. Don't mask it.
Change-Id: I6625ded0162ee3a96b92188844d0d2d6c30101c2
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7162
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Change-Id: I4d950dc0a1421036418f2e5c1f0ed8eca86efc1a
Signed-off-by: Marc Schink <dev@zapb.de>
Reviewed-on: https://review.openocd.org/c/openocd/+/7390
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Simply move numicro M0 flash write assembly to contrib/loaders. Also,
modify corresponding Makefile and generated numicro_m0.inc.
To make the path more general, this patch rename the path
"contrib/loaders/flash/numicro_m4" to "contrib/loaders/flash/numicro" as
well.
Signed-off-by: Jian-Hong Pan <chienhung.pan@gmail.com>
Change-Id: I9adea24c2b3c97319a9b015cf50257f3d131dc26
Reviewed-on: https://review.openocd.org/c/openocd/+/7346
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Simply move numicro M4 flash write assembly to contrib/loaders. Also,
add corresponding Makefile and generated numicro_m4.inc.
Signed-off-by: Jian-Hong Pan <chienhung.pan@gmail.com>
Change-Id: I22b8be0a245857335b11bd0b538db415fc34748d
Reviewed-on: https://review.openocd.org/c/openocd/+/7343
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
This patch is picked from the flash part of OpenOCD-Nuvoton's commit
("flash: supported Nuvoton M4 series. jtag: Used HW reset instead of
auto reset. tcl: added a configuration file for Nuvoton M4 series.") [1]
to support flashing Nuvoton's Cortex-M4 chips: M541 & NUC442/472 series.
The code comes from the commit basically. Jian-Hong Pan tweaked for the
compatibility with current OpenOCD. So, leave the author as Zale Yu.
[1]: https://github.com/OpenNuvoton/OpenOCD-Nuvoton/commit/c2d5b8bfc705
Signed-off-by: Zale Yu <cyyu@nuvoton.com>
Signed-off-by: Jian-Hong Pan <chienhung.pan@gmail.com>
Change-Id: I9dc69eccb851df14c1b0ce2f619d7b3da0aa92aa
Reviewed-on: https://review.openocd.org/c/openocd/+/7329
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
This patch is picked from the flash part of OpenOCD-Nuvoton's commit
("flash: supported Nuvoton M4 series. jtag: Used HW reset instead of
auto reset. tcl: added a configuration file for Nuvoton M4 series.") [1]
It reorders Nuvoton MCU part list and spreads out the way to define the
banks' base address & size of the parts.
The code comes from the commit basically. Jian-Hong Pan tweaked for the
compatibility with current OpenOCD. So, leave the author as Zale Yu.
[1]: https://github.com/OpenNuvoton/OpenOCD-Nuvoton/commit/c2d5b8bfc705
Signed-off-by: Zale Yu <cyyu@nuvoton.com>
Signed-off-by: Jian-Hong Pan <chienhung.pan@gmail.com>
Change-Id: I1f21f54dfdf53e5b8ea04d803347d1dbc8c321a0
Reviewed-on: https://review.openocd.org/c/openocd/+/7339
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Change-Id: I6d8e0fbfa7e05f26295fc22733c65c11f7460b51
Signed-off-by: Tarek BOCHKATI <tarek.bouchkati@st.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7282
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Tested-by: jenkins
|
|
Do not read ID from SPI flash and suppress autodetection
if non-zero flash bank size is configured.
Change-Id: Idcf9ee6ca17f9fa89964a60da7bf11e47b4af5e7
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7241
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
The HiFive Inventor uses this flash chip, so adding it will allow for
openocd to be used to program it. These values were taken from the
chip's documentation.
Signed-off-by: Fawaz Tirmizi <fawaz@rivosinc.com>
Change-Id: I15c9d35f99d4500f73134cdc2d1b9ab6279b491c
Reviewed-on: https://review.openocd.org/c/openocd/+/7135
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Add new chip info and tcl target
Change-Id: Ib9d33d1b145a8659857b7a6cc9c5acba047f41d1
Signed-off-by: Kyle Schwarz <zeranoe@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7081
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Fixes "variable set but not used" errors.
Tested with Homebrew clang version 13.0.1
Signed-off-by: Erhan Kurubas <erhan.kurubas@espressif.com>
Change-Id: Ia90baf5b4857db2b5569ebe6adbbb832de772aad
Reviewed-on: https://review.openocd.org/c/openocd/+/6971
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Signed-off-by: Erhan Kurubas <erhan.kurubas@espressif.com>
Co-authored-by: Erhan Kurubas <erhan.kurubas@espressif.com>
|
|
Flashing a SAMD21J17D was failing during NVM erase. The samd21
datasheet specifies that one cause of error conditions is executing an
NVM command while the previous command is still running. The solution
is to wait for INTFLAG.READY after a command is issued.
SAMD21J17A was not exhibiting this problem. Perhaps the later silicon
revision has slower NVM erase times.
Signed-off-by: Dan Stahlke <dan@stahlke.org>
Change-Id: I19745dae4d3fc6e3a7611dcac628e067cb41e0f0
Reviewed-on: https://review.openocd.org/c/openocd/+/7391
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
|
|
The variable retval is assigned a value that is never used.
Scan-build reports:
Although the value stored to 'retval' is used in the
enclosing expression, the value is never actually read
from 'retval'.
Drop the dead assignment.
Change-Id: I11588dee748a55d52aa7f35bc1967b7df55af7fc
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7379
Tested-by: jenkins
|
|
Change-Id: I0ff1e2102175ee952b066b325c9acbcb598b3af7
Signed-off-by: Marc Schink <dev@zapb.de>
Reviewed-on: https://review.openocd.org/c/openocd/+/7378
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Change-Id: Id003adb574085cdd603cc13aeb6f2efec73593f1
Signed-off-by: Andreas Bolsch <hyphen0break@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7345
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
target_run_flash_async_algorithm expects the source_buffer to have
at least 2 words reserved for read and write pointers in addition to the
FIFO buffer. If the size of the data to be flashed is <= 8 bytes then
the flash function will fail with "corrupted fifo read pointer" error.
Ensure the allocated buffer is big enough to hold both FIFO buffer and
read/write pointers.
Change-Id: I09c22eaac517b8cfea8e0b463f5deb6b98afd267
Signed-off-by: Simon Smiganovski <simon.smiganovski@fruitcore.de>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7342
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
The variable retval is assigned a value that is never used, as it
is reassigned few lines below.
Drop the dead assignment.
Change-Id: Id4e9134408fab3e04936d36e95724bf8d3ab55aa
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7304
Tested-by: jenkins
|
|
ST-Link v2 dongles can be used with many cortex-m parts, but they have
one limitation -- they can only perform 8-bit and 32-bit writes to the
target. 16-bit writes are done using a pair of 8-bit writes. While not
usually an issue, in the case of the at91samd flash driver, the 16-bit
'command' register must have both halves written in the same
operation.
Fortunately, this register has two pad bytes above it in the address
space, making it safe to always access with 32-bit operations.
Change-Id: I44b0db9406982a8db5818c0533d3101618741db2
Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7234
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
The num_reg_params parameter of target_run_algorithm() was not
updated when setting "sp" was introduced. Therefore "sp" as the last
register parameter was not passed to a target algo.
Introduce a new helper variable with correct count of register parameters
and use it everywhere needed.
Change-Id: I934a71380783d98917167f1569145808ef23540f
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7225
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Jonathan Bell <jonathan@raspberrypi.com>
|
|
Change-Id: Idf3bce842b4507c1f12692b5fbcd6730637de9db
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7216
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Jonathan Bell <jonathan@raspberrypi.com>
Tested-by: jenkins
|
|
Change-Id: Ic76e1c6306ece18b3590beaad4d5b224d4449aa0
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7188
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Tested-by: jenkins
|
|
Flash read_id/erase/write operation on running target failed
in target_run_algorithm() anyway. It generated lot of error messages.
Check the target state and bail out early if target is running.
Change-Id: I903f5f38c8e61016e5002b235e5f07803bd2ec4e
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7215
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Jonathan Bell <jonathan@raspberrypi.com>
|
|
SPI flash erase often takes longer than the fixed timeout 3 seconds.
Introduce a configurable timeout_ms parameter to rp2040_call_rom_func().
Compute the erase timeout from the number of blocks to be erased.
While on it make the timeouts shorter for connect flash, flush cache and
enter/exit xip (1 second is enough).
Change-Id: I552bfa317ee17064de3a54ec2f0c63e84ba87222
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7214
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Jonathan Bell <jonathan@raspberrypi.com>
|
|
The size of the flash write buffer should be rounded
down to the multiply of flash page size.
Using write chunks of unadjusted size results in write of chunks
unaligned to flash pages.
Change-Id: If7931362ee193dff4dc2df7ec78f13530658cf08
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7187
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
While on it restore memory-mapped mode also after flash erase
(originally was restored after flash write only).
Change-Id: I5e153b79ac27a8439f57239ce90ce8a79c0bb8a1
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7186
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Prepend stack_grab_and_prep() function name by rp2040_ prefix.
Introduce target helper variable in rp2040_stack_grab_and_prep()
and use it instead of dereferencing bank->target several times.
Move flash ID reading code to the new rp2040_spi_read_flash_id()
function.
Change-Id: I9d6e51e17e36e6230155a586065499f2f260089a
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7185
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
With the old checkpatch we cannot use the correct format for the
SPDX tags in the file .c, in fact the C99 comments are not allowed
and we had to use the block comment.
With the new checkpatch, let's switch to the correct SPDX format.
Change created automatically through the command:
sed -i \
's,^/\* *\(SPDX-License-Identifier: .*[^ ]\) *\*/$,// \1,' \
$(find src/ contrib/ -name \*.c)
Change-Id: I6da16506baa7af718947562505dd49606d124171
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7153
Tested-by: jenkins
|
|
Change-Id: I18c62ddb3963c357c7ce5dfc067c8d63fbc82b99
Signed-off-by: Marc Schink <dev@zapb.de>
Reviewed-on: https://review.openocd.org/c/openocd/+/7196
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Change-Id: Id1ad72e74d6a1bddc4dfe46dcf715ef74e19a27f
Signed-off-by: Toms Stūrmanis <toms.sturmanis@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7194
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
|
|
Variables should not be declared in the include file, otherwise
multiple include will cause multiple instances.
Move the declaration in the C file and make it static.
Change-Id: I8b4884cba643a792a78df4e123aa324b19d92279
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7172
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Tested-by: jenkins
|
|
Symbols that are not exported should be declared as static.
Change-Id: I6a059080bbba9b3559d26c641b217be8be3b199e
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7169
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Tested-by: jenkins
|
|
Add new flash driver for internal flash of onsemi RSL10 device.
Valgrind-clean. Clang AddressSanitizer shows no errors.
Signed-off-by: Toms Stūrmanis <toms.sturmanis@gmail.com>
Change-Id: I8030542cb9805e94f56d7a69404cef5d88d6dd5a
Reviewed-on: https://review.openocd.org/c/openocd/+/7115
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
|
|
Without the help of checkpatch, some CamelCase symbol passed
through the filter of maintainer's review.
Drop them.
Change-Id: If5fb07b2ffb89e853dd2a61f20d4134aa6e20d24
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Fixes: 48f267d4adea ("flash/stm32l4x: avoid using magic numbers for device ids")
Fixes: 5ab74bde0654 ("semihosting: User defined operation, Tcl command exec on host")
Reviewed-on: https://review.openocd.org/c/openocd/+/7154
Tested-by: jenkins
|
|
kinetis.c:994:61: error: '%u' directive output may be truncated
writing between 1 and 10 bytes into a region of size 4
[-Werror=format-truncation=]
tested with scan-build-14
Signed-off-by: Erhan Kurubas <erhan.kurubas@espressif.com>
Change-Id: I72d141a3f8e19ca3596beee2be8434fc8492946f
Reviewed-on: https://review.openocd.org/c/openocd/+/7140
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Tested-by: jenkins
|
|
While on it rename misleading write_algorithm_sp to write_algorithm_stack
and change messages referring 'stack pointer' instead of stack.
No functional change.
Change-Id: Ibb9897d3f01734812ed0f8bc8cd43b935a573f8a
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7132
Tested-by: jenkins
Reviewed-by: Salvatore Giorgio Pecorino <salvatore-giorgio.pecorino@st.com>
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Change-Id: I016fc9ae037fae75528850d35da059d1db5a4d45
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7131
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
FLASH_MAX_ERROR_STR is not used since commit 815c3b353307
(merged in ~2008)
Change-Id: Ic117a2e3d22235c31dc14533b6564ebf5a13ae58
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7121
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
The value of struct flash_driver::command can be NULL when the
flash driver does not need to add any new command.
Remove empty command definitions.
Change-Id: I5413967d4069030234469822d24e9825425ae012
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7120
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Tested-by: jenkins
|
|
When printing memory sizes standard ISO 80000-1 prefixes should be used.
Also a space should be added between any number and its unit according
to papers publication rules.
Change-Id: Id1d35e210766b55c201de4e80ac165d8d0414d0a
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/6416
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
The same flag 'jtag_poll' is currently used as local data for the
command 'poll' and to temporarily mask the target polling.
This can cause unexpected behavior if the command 'poll' is
executed while polling is temporarily masked.
Add a new flag 'jtag_poll_en' to hold the temporarily mask
condition and keep 'jtag_poll' for the 'poll' command only.
While there, change the initial assignment of 'jtag_poll' using
the proper boolean value.
Change-Id: I18dcf7c65b07aefadf046caaa2fcd2d74fa6fbae
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: https://review.openocd.org/c/openocd/+/7009
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
Tested-by: jenkins
|
|
The flash/nor subsystem uses bus_width and chip_width for CFI
external flash only. Drop setting these values for internal flash.
Change-Id: I64e79ab38b6e39e845ff96fbf4f60145e3b9690a
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7098
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
|
|
Kinetis 100 MHz rev 1.x devices have no SMC and hence need different
checking of the run mode. Details about the differences between rev 1.x
and 2.x of the Kinetis 100 MHz series can be found here:
https://www.nxp.com.cn/docs/en/application-note/AN4445.pdf
Signed-off-by: Martin Hierholzer <martin.hierholzer@desy.de>
Change-Id: Ib705385a931275159bdae9b31caecc6ec9c0da1e
Reviewed-on: https://review.openocd.org/c/openocd/+/7015
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
|
|
Change-Id: I09d3ed20966b37ec63c09c2ffb0e0403986cb1e5
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/7001
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Tim Newsome <tim@sifive.com>
|