scripts: runners: openocd: Enable thread awareness
Zephyr thread awareness is available for openocd but boards don't
have debuggers configuration. This configure OpenOCD runner
automatically to complete configuration.
User still require enable CONFIG_DEBUG_THREAD_INFO=y to visualize
thread debug information.
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
diff --git a/scripts/west_commands/run_common.py b/scripts/west_commands/run_common.py
index f40c64f..e85b714 100644
--- a/scripts/west_commands/run_common.py
+++ b/scripts/west_commands/run_common.py
@@ -356,8 +356,8 @@
return None
- def config(attr):
- return getattr(args, attr, None) or yaml_config.get(attr)
+ def config(attr, default=None):
+ return getattr(args, attr, None) or yaml_config.get(attr, default)
return RunnerConfig(build_dir,
yaml_config['board_dir'],
@@ -366,7 +366,7 @@
output_file('bin'),
config('gdb'),
config('openocd'),
- config('openocd_search'))
+ config('openocd_search', []))
def dump_traceback():
# Save the current exception to a file and return its path.