Get ARM none EABI toolchain
arm-none-eabi-gdb includedhttp://www.codesourcery.com/sgpp/lite/arm/portal/package7813/public/arm-none-eabi/arm-2010.09-51-arm-none-eabi-i686-pc-linux-gnu.tar.bz2
Get module symbol information
Check Build/BeagleBoard/DEBUG_ARMGCC/FV/FVMAIN_COMPACT.Fv.mapGet .textbaseaddress and .databaseaddress
Load symbol information
arm-none-eabi-gdb(gdb) add-symbol-file <BEAGLEROOT>/Build/BeagleBoard/DEBUG_ARMGCC/ARM/ArmPlatformPkg/PrePi/PeiUniCore/DEBUG/ArmPlatformPrePiUniCore.dll 0x0080008180 -s data 0x008001b5e4
add symbol table from file <BEAGLEROOT>/Build/BeagleBoard/DEBUG_ARMGCC/ARM/ArmPlatformPkg/PrePi/PeiUniCore/DEBUG/ArmPlatformPrePiUniCore.dll" at
.text_addr = 0x80008180
data_addr = 0x8001b5e4
(y or n) y
Reading symbols from <BEAGLEROOT>/Build/BeagleBoard/DEBUG_ARMGCC/ARM/ArmPlatformPkg/PrePi/PeiUniCore/DEBUG/ArmPlatformPrePiUniCore.dll...warning: section data not found in <BEAGLEROOT>/Build/BeagleBoard/DEBUG_ARMGCC/ARM/ArmPlatformPkg/PrePi/PeiUniCore/DEBUG/ArmPlatformPrePiUniCore.dll
done.
Start ARM qEmu
qemu-system-arm -M beagle -s -S -serial stdio -sd beagle.img-s for waiting for gdb connection
-S for stopping execution when qEmu starts up
Connecting qEmu using GDB
(gdb) target remote :1234Remote debugging using :1234
0x40014000 in ?? ()
Example
(gdb) b _ModuleEntryPoint
Breakpoint 1 at 0x80008188: file /home/kurt/programming/edk2/src/beagle/Build/BeagleBoard/DEBUG_ARMGCC/ARM/ArmPlatformPkg/PrePi/PeiUniCore/OUTPUT/Arm/ModuleEntryPoint.iii, line 39.
Connecting qEmu using DDD
sudo apt-get install dddddd --debugger arm-none-eabi-gdb
In DDD using GDB command line
Get module symbol informationLoad symbol information
Connecting qEmu using GDB
沒有留言:
張貼留言