This is an automated email from Gerrit.
Tarek BOCHKATI (tar...@gm...) just uploaded a new patch set to Gerrit, which you can find at http://openocd.zylin.com/6066
-- gerrit
commit a7c436d1f6f8dd72aa937077bbc788ba2cf43f70
Author: Tarek BOCHKATI <tar...@gm...>
Date: Thu Feb 18 00:35:48 2021 +0100
tcl/target: add BCM2711 configuration file
The Broadcom BCM2711 used in Raspberry Pi 4
No documentation was found on Broadcom website
Partial information are available in raspberry pi website:
https://www.raspberrypi.org/documentation/hardware/raspberrypi/bcm2711/
Change-Id: I3db6c9af520af8ab4c21ad35ff0f2db28efc0325
Signed-off-by: Tarek BOCHKATI <tar...@gm...>
diff --git a/tcl/target/bcm2711.cfg b/tcl/target/bcm2711.cfg
new file mode 100644
index 0000000..e2f6114
--- /dev/null
+++ b/tcl/target/bcm2711.cfg
@@ -0,0 +1,59 @@
+# The Broadcom BCM2711 used in Raspberry Pi 4
+# No documentation was found on Broadcom website
+# Partial information are available in raspberry pi website:
+# https://www.raspberrypi.org/documentation/hardware/raspberrypi/bcm2711/
+
+if { [info exists CHIPNAME] } {
+ set _CHIPNAME $CHIPNAME
+} else {
+ set _CHIPNAME bcm2711
+}
+
+if { [info exists CHIPCORES] } {
+ set _cores $CHIPCORES
+} else {
+ set _cores 4
+}
+
+if { [info exists DAP_TAPID] } {
+ set _DAP_TAPID $DAP_TAPID
+} else {
+ set _DAP_TAPID 0x4ba00477
+}
+
+jtag newtap $_CHIPNAME cpu -expected-id $_DAP_TAPID -irlen 4
+adapter speed 4000
+
+dap create $_CHIPNAME.dap -chain-position $_CHIPNAME.cpu
+
+# these addresse are obtained from the ROM table via 'dap info 0' command
+set _DBGBASE {0x80410000 0x80510000 0x80610000 0x80710000}
+set _CTIBASE {0x80420000 0x80520000 0x80620000 0x80720000}
+
+for { set _core 0 } { $_core < $_cores } { incr _core } {
+
+ cti create $_CHIPNAME.cti$_core -dap $_CHIPNAME.dap -ap-num 0 \
+ -baseaddr [lindex $_CTIBASE $_core]
+
+ set _command "target create $_CHIPNAME.cpu$_core aarch64 -dap $_CHIPNAME.dap \
+ -ap-num 0 -dbgbase [lindex $_DBGBASE $_core] -cti $_CHIPNAME.cti$_core"
+
+ if { $_core != 0 } {
+ set _command "$_command -defer-examine"
+ set _smp_command "$_smp_command $_CHIPNAME.cpu$_core"
+ } else {
+ set _smp_command "target smp $_CHIPNAME.cpu$_core"
+ }
+
+ eval $_command
+}
+
+eval $_smp_command
+
+
+# AHB-AP for direct access
+target create $_CHIPNAME.ap mem_ap -dap $_CHIPNAME.dap -ap-num 0
+
+# default target is cpu0
+targets $_CHIPNAME.cpu0
+
--
|