aboutsummaryrefslogtreecommitdiff
path: root/tcl/board
diff options
context:
space:
mode:
authorTim Newsome <tim@sifive.com>2021-04-13 11:22:43 -0700
committerTim Newsome <tim@sifive.com>2021-04-13 11:26:25 -0700
commit7420382a4d9453bf4bf72f2e42728136f9a3b7bb (patch)
tree4aa04d3b401b9b9da8c29fda93e6ff23a70b29f1 /tcl/board
parent05e962e03a9642f883c0a91c38409ba89ad4fa7c (diff)
parent0f06d943366154963c6f5eb70f52e70f64fe5c71 (diff)
downloadriscv-openocd-7420382a4d9453bf4bf72f2e42728136f9a3b7bb.zip
riscv-openocd-7420382a4d9453bf4bf72f2e42728136f9a3b7bb.tar.gz
riscv-openocd-7420382a4d9453bf4bf72f2e42728136f9a3b7bb.tar.bz2
Merge branch 'master' into from_upstream
Conflicts: .github/workflows/snapshot.yml NEWS configure.ac contrib/loaders/checksum/riscv_crc.c jimtcl src/helper/time_support.h src/jtag/drivers/arm-jtag-ew.c src/rtos/FreeRTOS.c src/target/image.c src/target/riscv/riscv.c Change-Id: I043624ba540d4672fc123dddb2066bcb9c6b5a05
Diffstat (limited to 'tcl/board')
-rw-r--r--tcl/board/altera_sockit.cfg2
-rw-r--r--tcl/board/ampere_emag8180.cfg38
-rw-r--r--tcl/board/olimex_stm32_h405.cfg8
-rw-r--r--tcl/board/ti_am642evm.cfg24
-rw-r--r--tcl/board/ti_am654evm.cfg24
-rw-r--r--tcl/board/ti_j7200evm.cfg24
-rw-r--r--tcl/board/ti_j721evm.cfg24
-rw-r--r--tcl/board/zy1000.cfg117
8 files changed, 143 insertions, 118 deletions
diff --git a/tcl/board/altera_sockit.cfg b/tcl/board/altera_sockit.cfg
index eb4c863..b7c7993 100644
--- a/tcl/board/altera_sockit.cfg
+++ b/tcl/board/altera_sockit.cfg
@@ -12,7 +12,7 @@ adapter driver usb_blaster
source [find target/altera_fpgasoc.cfg]
# If the USB Blaster II were supported, these settings would be needed
-#usb_blaster_vid_pid 0x6810 0x09fb
+#usb_blaster_vid_pid 0x09fb 0x6810
#usb_blaster_device_desc "USB-Blaster II"
adapter speed 100
diff --git a/tcl/board/ampere_emag8180.cfg b/tcl/board/ampere_emag8180.cfg
new file mode 100644
index 0000000..a122e02
--- /dev/null
+++ b/tcl/board/ampere_emag8180.cfg
@@ -0,0 +1,38 @@
+#
+# OpenOCD Board Configuration for eMAG Development Platform
+#
+# Copyright (c) 2019-2021, Ampere Computing LLC
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of
+# the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program;
+#
+#
+
+#
+# Configure JTAG speed
+#
+
+adapter speed 2000
+
+#
+# Configure Resets
+#
+
+jtag_ntrst_delay 100
+reset_config trst_only
+
+#
+# Configure Targets
+#
+
+source [find target/ampere_emag.cfg]
diff --git a/tcl/board/olimex_stm32_h405.cfg b/tcl/board/olimex_stm32_h405.cfg
new file mode 100644
index 0000000..f2f1d7f
--- /dev/null
+++ b/tcl/board/olimex_stm32_h405.cfg
@@ -0,0 +1,8 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+# Olimex STM32-H405 eval board
+# https://www.olimex.com/Products/ARM/ST/STM32-H405/
+
+# Work-area size (RAM size) = 128kB for STM32F405RG device
+set WORKAREASIZE 0x20000
+
+source [find target/stm32f4x.cfg]
diff --git a/tcl/board/ti_am642evm.cfg b/tcl/board/ti_am642evm.cfg
new file mode 100644
index 0000000..e97fdcf
--- /dev/null
+++ b/tcl/board/ti_am642evm.cfg
@@ -0,0 +1,24 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+# Copyright (C) 2019-2021 Texas Instruments Incorporated - http://www.ti.com/
+#
+# Texas Instruments AM642 EVM
+#
+
+# AM642 EVM has an xds110 onboard.
+source [find interface/xds110.cfg]
+
+transport select jtag
+
+# default JTAG configuration has only SRST and no TRST
+reset_config srst_only srst_push_pull
+
+# delay after SRST goes inactive
+adapter srst delay 20
+
+if { ![info exists SOC] } {
+ set SOC am642
+}
+
+source [find target/ti_k3.cfg]
+
+adapter speed 250
diff --git a/tcl/board/ti_am654evm.cfg b/tcl/board/ti_am654evm.cfg
new file mode 100644
index 0000000..a661f60
--- /dev/null
+++ b/tcl/board/ti_am654evm.cfg
@@ -0,0 +1,24 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+# Copyright (C) 2019-2021 Texas Instruments Incorporated - http://www.ti.com/
+#
+# Texas Instruments AM654 EVM/IDK Base Board
+#
+
+# AM654 EVM has an xds110 onboard.
+source [find interface/xds110.cfg]
+
+transport select jtag
+
+# default JTAG configuration has only SRST and no TRST
+reset_config srst_only srst_push_pull
+
+# delay after SRST goes inactive
+adapter srst delay 70
+
+if { ![info exists SOC] } {
+ set SOC am654
+}
+
+source [find target/ti_k3.cfg]
+
+adapter speed 2500
diff --git a/tcl/board/ti_j7200evm.cfg b/tcl/board/ti_j7200evm.cfg
new file mode 100644
index 0000000..cc70056
--- /dev/null
+++ b/tcl/board/ti_j7200evm.cfg
@@ -0,0 +1,24 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+# Copyright (C) 2019-2021 Texas Instruments Incorporated - http://www.ti.com/
+#
+# Texas Instruments J7200 EVM
+#
+
+# J7200 EVM has an xds110 onboard.
+source [find interface/xds110.cfg]
+
+transport select jtag
+
+# default JTAG configuration has only SRST and no TRST
+reset_config srst_only srst_push_pull
+
+# delay after SRST goes inactive
+adapter srst delay 20
+
+if { ![info exists SOC] } {
+ set SOC j7200
+}
+
+source [find target/ti_k3.cfg]
+
+adapter speed 2500
diff --git a/tcl/board/ti_j721evm.cfg b/tcl/board/ti_j721evm.cfg
new file mode 100644
index 0000000..d0c4b74
--- /dev/null
+++ b/tcl/board/ti_j721evm.cfg
@@ -0,0 +1,24 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+# Copyright (C) 2019-2021 Texas Instruments Incorporated - http://www.ti.com/
+#
+# Texas Instruments J721E EVM
+#
+
+# J721E EVM has an xds110 onboard.
+source [find interface/xds110.cfg]
+
+transport select jtag
+
+# default JTAG configuration has only SRST and no TRST
+reset_config srst_only srst_push_pull
+
+# delay after SRST goes inactive
+adapter srst delay 20
+
+if { ![info exists SOC] } {
+ set SOC j721e
+}
+
+source [find target/ti_k3.cfg]
+
+adapter speed 2500
diff --git a/tcl/board/zy1000.cfg b/tcl/board/zy1000.cfg
deleted file mode 100644
index e0d1ccf..0000000
--- a/tcl/board/zy1000.cfg
+++ /dev/null
@@ -1,117 +0,0 @@
-#Script for ZY1000
-
-#Atmel ties SRST & TRST together, at which point it makes
-#no sense to use TRST, but use TMS instead.
-#
-#The annoying thing with tying SRST & TRST together is that
-#there is no way to halt the CPU *before and during* the
-#SRST reset, which means that the CPU will run a number
-#of cycles before it can be halted(as much as milliseconds).
-reset_config srst_only srst_pulls_trst
-
-
-if { [info exists CHIPNAME] } {
- set _CHIPNAME $CHIPNAME
-} else {
- set _CHIPNAME zy1000
-}
-
-if { [info exists ENDIAN] } {
- set _ENDIAN $ENDIAN
-} else {
- set _ENDIAN little
-}
-
-
-#jtag scan chain
-if { [info exists CPUTAPID] } {
- set _CPUTAPID $CPUTAPID
-} else {
- set _CPUTAPID 0x1f0f0f0f
-}
-jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_CPUTAPID
-
-set _TARGETNAME $_CHIPNAME.cpu
-target create $_TARGETNAME arm7tdmi -endian $_ENDIAN -chain-position $_TARGETNAME
-
-# at CPU CLK <32kHz this must be disabled
-arm7_9 fast_memory_access enable
-arm7_9 dcc_downloads enable
-
-set _FLASHNAME $_CHIPNAME.flash
-flash bank $_FLASHNAME cfi 0x01000000 0x200000 2 2 $_TARGETNAME
-
-$_TARGETNAME configure -event reset-init {
- # Set up chip selects & timings
- mww 0xFFE00000 0x0100273D
- mww 0xFFE00004 0x08002125
- mww 0xFFEe0008 0x02002125
- mww 0xFFE0000c 0x03002125
- mww 0xFFE00010 0x40000000
- mww 0xFFE00014 0x50000000
- mww 0xFFE00018 0x60000000
- mww 0xFFE0001c 0x70000000
- mww 0xFFE00020 0x00000001
- mww 0xFFE00024 0x00000000
-
- # remap
- mww 0xFFFFF124 0xFFFFFFFF
- mww 0xffff0010 0x100
- mww 0xffff0034 0x100
-
- #disable 16x5x UART interrupts
- mww 0x08020004 0
-}
-
-$_TARGETNAME configure -event gdb-attach {
- # Without this gdb-attach will first time as probe will fail
- reset init
-}
-
-# required for usable performance. Used for lots of
-# other things than flash programming.
-$_TARGETNAME configure -work-area-phys 0x00020000 -work-area-size 0x20000 -work-area-backup 0
-
-adapter speed 16000
-
-
-proc production_info {} {
- return "Serial number is official MAC number. Format XXXXXXXXXXXX"
-}
-
-# There is no return value from this procedure. If it is
-# successful it does not throw an exception
-#
-# Progress messages are output via puts
-proc production {firmwarefile serialnumber} {
- if {[string length $serialnumber]!=12} {
- echo "Invalid serial number"
- return
- }
-
- echo "Power cycling target"
- power off
- sleep 3000
- power on
- sleep 1000
- reset init
- flash write_image erase $firmwarefile 0x1000000 bin
- verify_image $firmwarefile 0x1000000 bin
-
- # Big endian... weee!!!!
- echo "Setting MAC number to $serialnumber"
- flash fillw [expr 0x1030000-0x8] "0x[string range $serialnumber 2 3][string range $serialnumber 0 1]0000" 1
- flash fillw [expr 0x1030000-0x4] "0x[string range $serialnumber 10 11][string range $serialnumber 8 9][string range $serialnumber 6 7][string range $serialnumber 4 5]" 1
- echo "Production successful"
-}
-
-
-proc production_test {} {
- power on
- sleep 1000
- target_request debugmsgs enable
- reset run
- sleep 25000
- target_request debugmsgs disable
- return "See IP address above..."
-}