cl_utils.c: Try jtag scan if swd scan did not give results.

This commit is contained in:
Uwe Bonnes 2021-03-14 13:23:46 +01:00 committed by UweBonnes
parent 5288eef617
commit 637d76b585
1 changed files with 4 additions and 0 deletions

View File

@ -364,6 +364,10 @@ int cl_execute(BMP_CL_OPTIONS_t *opt)
num_targets = platform_jtag_scan(NULL);
} else {
num_targets = platform_adiv5_swdp_scan(opt->opt_targetid);
if (!num_targets) {
DEBUG_INFO("Scan SWD failed, trying JTAG!\n");
num_targets = platform_jtag_scan(NULL);
}
}
if (!num_targets) {
DEBUG_WARN("No target found\n");