target: restructure dap support
[fw/openocd] / tcl / target / ti_msp432p4xx.cfg
index 8600867077c7433272961f3097526633ea929a96..461b595477cef8a218782db8f7679ec31c880220 100644 (file)
@@ -31,9 +31,10 @@ if { [using_jtag] } {
 }
 
 swj_newdap $_CHIPNAME cpu -irlen 4 -expected-id $_DAP_ID
+dap create $_CHIPNAME.dap -chain-position $_CHIPNAME.cpu
 
 set _TARGETNAME $_CHIPNAME.cpu
-target create $_TARGETNAME cortex_m -chain-position $_TARGETNAME
+target create $_TARGETNAME cortex_m -dap $_CHIPNAME.dap
 
 if { [info exists WORKAREASIZE] } {
        set _WORKAREASIZE $WORKAREASIZE