west debugserver: openocd: configure rtos

This enables thread awareness in the spawned OpenOCD server.

Signed-off-by: Bruno Mendes <bd_mendes@outlook.com>
This commit is contained in:
Bruno Mendes 2023-07-27 11:39:13 +01:00 committed by Maureen Helm
parent 724a5cd54f
commit 7da7742c66

View file

@ -356,6 +356,11 @@ class OpenOcdBinaryRunner(ZephyrBinaryRunner):
pre_init_cmd.append("-c")
pre_init_cmd.append(i)
if self.thread_info_enabled and self.supports_thread_info():
pre_init_cmd.append("-c")
rtos_command = '${} configure -rtos Zephyr'.format(self.target_handle)
pre_init_cmd.append(rtos_command)
cmd = (self.openocd_cmd + self.cfg_cmd +
['-c', 'tcl_port {}'.format(self.tcl_port),
'-c', 'telnet_port {}'.format(self.telnet_port),