Skip to content
Snippets Groups Projects
Commit c14e9526 authored by Philip Attfield's avatar Philip Attfield Committed by Joakim Bech
Browse files

rpi3: Add debugger config files


.gdbinit stores settings for loading the symbol files at the correct
addresses and pi3.cfg is the JTAG configuration file for OpenOCD.

Signed-off-by: default avatarJoakim Bech <joakim.bech@linaro.org>
Reviewed-by: default avatarJerome Forissier <jerome.forissier@linaro.org>
Reviewed-by: default avatarDavid Brown <david.brown@linaro.org>
parent 3f9250fc
No related branches found
No related tags found
No related merge requests found
target extended-remote localhost:3333
# to debug single core:
# in u-boot: setenv smp off ; boot
# substitute appropriate value from u-boot startup message (relocation offset)
add-symbol-file ../../../u-boot/u-boot 0x3af3a000
add-symbol-file ../../../arm-trusted-firmware/build/rpi3/debug/bl31/bl31.elf 0x08400000
add-symbol-file ../../../optee_os/out/arm/core/tee.elf 0x08420000
add-symbol-file ../../../linux/vmlinux 0xffffffc000080800
mon gdb_breakpoint_override hard
flushregs
# bl31_entrypoint
#b *0x08400000
# TEE entrypoint
#b *0x08420000
# Linux; primary core entry.
# Symbols for initial setup _do not align with vmlinux (elf)_. Debug at instruction
# level only.
# Symbols post MMU enable are correct.
#b *0x080000
mon halt
# RPi3b
tcl_port 5555
telnet_port 4444
gdb_port 3333
transport select jtag
adapter_khz 1000
jtag_ntrst_delay 100
reset_config trst_only separate
set _CHIPNAME rpi3b
set _TARGETNAME_0 $_CHIPNAME.cpu0
set _TARGETNAME_1 $_CHIPNAME.cpu1
set _TARGETNAME_2 $_CHIPNAME.cpu2
set _TARGETNAME_3 $_CHIPNAME.cpu3
jtag newtap $_CHIPNAME dap -irlen 4 -expected-id 0x4ba00477
target create $_TARGETNAME_0 aarch64 -chain-position $_CHIPNAME.dap -dbgbase 0x80010000 -ctibase 0x80018000
#target create $_TARGETNAME_1 aarch64 -chain-position $_CHIPNAME.dap -dbgbase 0x80012000 -ctibase 0x80019000
#target create $_TARGETNAME_2 aarch64 -chain-position $_CHIPNAME.dap -dbgbase 0x80014000 -ctibase 0x8001a000
#target create $_TARGETNAME_3 aarch64 -chain-position $_CHIPNAME.dap -dbgbase 0x80016000 -ctibase 0x8001b000
#target smp $_CHIPNAME.cpu3 $_CHIPNAME.cpu2 $_CHIPNAME.cpu1 $_CHIPNAME.cpu0
proc rpi3b_gdb_attach {target} {
echo "gdb attach halt ..."
targets 0
halt
}
$_TARGETNAME_0 configure -event gdb-attach {
halt
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment