tcl/target: add SPDX tag
[fw/openocd] / tcl / target / omap5912.cfg
1 # SPDX-License-Identifier: GPL-2.0-or-later
2
3 # TI OMAP5912 dual core processor
4 # http://focus.ti.com/docs/prod/folders/print/omap5912.html
5
6 if { [info exists CHIPNAME] } {
7    set _CHIPNAME $CHIPNAME
8 } else {
9    set _CHIPNAME omap5912
10 }
11
12 if { [info exists CPUTAPID] } {
13    set _CPUTAPID $CPUTAPID
14 } else {
15    # NOTE: validated with XOMAP5912 part
16    set _CPUTAPID 0x0692602f
17 }
18
19 adapter srst delay 100
20
21 # NOTE: presumes irlen 38 is the C55x DSP, matching BSDL for
22 # its standalone siblings (like TMS320VC5502) of the same era
23
24 #jtag scan chain
25 jtag newtap $_CHIPNAME dsp -irlen 38 -expected-id 0x03df1d81
26 jtag newtap $_CHIPNAME arm -irlen 4 -expected-id $_CPUTAPID
27 jtag newtap $_CHIPNAME unknown -irlen 8
28
29 set _TARGETNAME $_CHIPNAME.arm
30 target create $_TARGETNAME arm926ejs -chain-position $_TARGETNAME
31
32 proc omap5912_reset {} {
33         #
34         # halt target
35         #
36         poll
37         sleep 1
38         halt
39         wait_halt
40         #
41         # disable wdt
42         #
43         mww 0xfffec808 0x000000f5
44         mww 0xfffec808 0x000000a0
45
46         mww 0xfffeb048 0x0000aaaa
47         sleep 500
48         mww 0xfffeb048 0x00005555
49         sleep 500
50 }
51
52 # omap5912 lcd frame buffer as working area
53 $_TARGETNAME configure -work-area-phys 0x20000000 \
54         -work-area-size 0x3e800 -work-area-backup 0