target/arm_dap: clean up dap_configure code
authorTomas Vanek <vanekt@fbl.cz>
Mon, 15 Nov 2021 14:32:39 +0000 (15:32 +0100)
committerAntonio Borneo <borneo.antonio@gmail.com>
Sat, 20 Nov 2021 14:45:54 +0000 (14:45 +0000)
commitbb78fa10c77411bbdf665c17eac954b7741f2040
treec9398cdd338abec597bc153abb8c7664f56d4f7f
parent81afe6e3fdb1253659d7d5a1be9f4f444c2c18d5
target/arm_dap: clean up dap_configure code

dap_configure() contained first time init related tasks, as the call to
dap_init_instance() and the check for configured tap.

Move all first time init related stuff to dap_create() to make dap_configure()
usable in eventual stand-alone 'dap configure' command.

Change-Id: Ia86eadb4e960ce54e8581630d01af75720d2318d
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: https://review.openocd.org/c/openocd/+/6702
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Matthias Welwarsky <matthias@welwarsky.de>
src/target/arm_dap.c