2013年10月18日 星期五

Debugging Octeon u-boot with GDB+BDI2000

You can use GDB either in Octeon SDK (mips64-octeon-linux-gnu-gdb) or Linux multiarch version GDB (gdb-multiarch).

Do the following In GDB shell, or, edit .gdbinit at directory that you run gdb
# Give -nx will prevent prevent .gdbinit from executed

set architecture mips:octeon2
set heur 0
set remoteti 10
set mips abi n64
set os none
set endian big

target remote [BDI2000_IP]:2001


x/i $pc

n(next)
c(conti)
bt(backtrace)
br(break)



ddd --debugger mips64-octeon-linux-gnu-gdb



 GDB: Error: Remote 'g' packet reply is too long:
  1. Mismatch of architecture. To show supported architectures:
    set architecture
  2. (?) --with-expat 
  3. (?)gdb-multiarch
  4. (?)modifying gdbstub.c (in qemu sources) to send 64bit registers

qt4 - Problem gdb remote debugging - Remote 'g' packet reply is too long - Stack Overflow
http://stackoverflow.com/questions/4896316/problem-gdb-remote-debugging-remote-g-packet-reply-is-too-long

gdb - Remote 'g' packet reply is too long - Stack Overflow
http://stackoverflow.com/questions/8662468/remote-g-packet-reply-is-too-long

Question #193249 : Questions : GCC ARM Embedded
https://answers.launchpad.net/gcc-arm-embedded/+question/193249


gdb-remote
http://www.cs.sfu.ca/~fedorova/Tech/simics-guides-3.0.26/simics-reference-manual-public-all/topic96.html



 Whenever BDI2000 get connected,  the PC get reset.
- TARGET: processing power-up delay
- TARGET: processing user reset request
- Core#0: ID code is 0x19400399
- Core#0: IMP reg is 0xA1404001
- TARGET: resetting target passed
- TARGET: processing target startup ....
- TARGET: processing target startup passed
cnMIPS#0>info
    Core state        : debug mode
    Debug entry cause : JTAG break request
    Current PC        : 0xffffffffbfc00000
    Current SR        : 0x505000e4
    Current LR  (r31) : 0xffffffffc003c86c
    Current SP  (r29) : 0xffffffffffff9710
FIX: check the BDI cfg file, which might be tftped from your tftp server, under [TARGET] section, and see if there is a command "RESET JTAG". If so, comment the line. (If not, god bless you.....)


gdb + BDI2000
Home - Abatron AG
http://www.abatron.ch
Older Products - Abatron AG
http://www.abatron.ch/products/bdi-family/older-products.html
GNU Support - Abatron AG
http://www.abatron.ch/products/debugger-support/gnu-support.html
JTAG debug interface for GNU Debugger
http://www.abatron.ch/fileadmin/user_upload/products/pdf/ManGdb55xx-3000.pdf

bdiGDB
http://www.ultsol.com/index.php/component/content/article/8/31-bdigdb

Kernel Debugging with GDB
http://dslab.lzu.edu.cn:8080/docs/publications/kernel_gdb.pdf

USI AN#02-001a: Using the Abatron BDI2000 to Debug a Linux Kernel
http://www.recipes4linux.com/recipes/bdi2000/kerneldebug/Tool%20Talk%2002-001a-Debug-Linux%20Kernel.pdf

USI AN#03-001: Installing, Configuring and Using GDB for the PowerPC
http://www.ultsol.com/pdfs/Tool_Talk_03-001-Using-GDB-for-PowerPC.pdf

BDI2000Usage < Training < DENX
http://www.denx.de/wiki/view/Training/BDI2000Usage

DebuggingUBoot < DULG < DENX 
http://www.denx.de/wiki/DULG/DebuggingUBoot

BDI2000和GDB联合调试mips_智慧居_百度空间
http://hi.baidu.com/whvyawpbmtanove/item/b772c4a548d397f614329b13

Debugging on DaVinci using BDI2000 - Texas Instruments Wiki
http://processors.wiki.ti.com/index.php/Debugging_on_DaVinci_using_BDI2000








沒有留言: