openocd/src
Frank Dischner df75bbd536 FreeRTOS: Always show current execution before scheduler is started
Previously, if the target was halted before the FreeRTOS scheduler was
started but after at least one thread was created, then the current thread
would be set to whichever thread had the highest priority. In addition to
being misleading, because that thread is not actually running, it can
cause issues with gdb. For instance, breaking somewhere before the first
thread is created will show the current execution as the current thread,
but stepping over a line that creates a thread will cause the current
thread to switch to the newly created thread and the current execution to
disappear. The sudden disappearance of the current execution thread seems
to confuse some versions of gdb.

With this change, the value of xSchedulerRunning is checked to determine
whether the scheduler has been started. If it hasn't, then a fake
'current execution' thread is always created and made the current thread.

Signed-off-by: Frank Dischner <frank.dischner@gmail.com>
Change-Id: Ide0fe7d9ffb9fac95cee4c805735f434c7c4934d
Reviewed-on: https://review.openocd.org/c/openocd/+/6935
Tested-by: jenkins
Reviewed-by: Asier Llano <asierllano@gmail.com>
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
2022-08-08 20:48:10 +00:00
..
flash flash/nor/fespi: check target type 2022-08-01 08:59:39 +00:00
helper helper/jim-nvp: avoid camelcase error by deprecated API 2022-07-23 13:59:49 +00:00
jtag drivers/vdebug: add support for DAP level interface 2022-07-30 08:48:21 +00:00
pld openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
rtos FreeRTOS: Always show current execution before scheduler is started 2022-08-08 20:48:10 +00:00
rtt openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
server openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
svf openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
target target/cortex_a: remove unused CORTEX_A15_COMMON_MAGIC 2022-08-08 19:59:22 +00:00
transport openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
xsvf openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
Makefile.am openocd: build: add SPDX tag 2022-07-23 13:06:38 +00:00
hello.c openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
hello.h openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
main.c openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
openocd.c openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
openocd.h openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00