summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRegia König2022-08-22 10:55:43 +0200
committerRegia König2022-08-22 10:55:43 +0200
commite1b2285a8a6d65be75901cbf11375de42f30eb7a (patch)
tree7e49e1f3b57cbe07f7308775bc558fc8166461cf
parentSave Makefile for Memtest86plus. Object files have debug symbols in this version (diff)
downloadmemtest86-e1b2285a8a6d65be75901cbf11375de42f30eb7a.tar.gz
memtest86-e1b2285a8a6d65be75901cbf11375de42f30eb7a.tar.xz
memtest86-e1b2285a8a6d65be75901cbf11375de42f30eb7a.zip
Save commands to get a successfull execution with gdb
-rw-r--r--GNU_efi_HelloWorld/gdb_procedure18
-rw-r--r--test_code/OVMF_VARS.fdbin540672 -> 540672 bytes
-rw-r--r--test_code/gdbscript5
3 files changed, 21 insertions, 2 deletions
diff --git a/GNU_efi_HelloWorld/gdb_procedure b/GNU_efi_HelloWorld/gdb_procedure
new file mode 100644
index 0000000..db39c70
--- /dev/null
+++ b/GNU_efi_HelloWorld/gdb_procedure
@@ -0,0 +1,18 @@
+../test_code: ./test.sh --- and run hello.efi
+../test_code: cat debug.log | grep hello -A 5
+ Loading driver at 0x0000657B000 EntryPoint=0x0000657E000
+
+(gdb) file hda_contents/hello.efi
+(gbb) info files
+ ...
+ Entry point: 0x3000
+ 0x0000000000003000 - 0x0000000000008980 is .text
+ ...
+ 0x000000000000a000 - 0x000000000000bd00 is .data
+ ....
+(gdb) file // unload file
+(gdb) add-symbol-file ../GNU_efi_HelloWorld/hello.debug 0x657E000 -s .data 0x6585000
+
+(gdb) b efi_main
+(gdb) b *0x657e260
+
diff --git a/test_code/OVMF_VARS.fd b/test_code/OVMF_VARS.fd
index 02ec986..5cc4003 100644
--- a/test_code/OVMF_VARS.fd
+++ b/test_code/OVMF_VARS.fd
Binary files differ
diff --git a/test_code/gdbscript b/test_code/gdbscript
index 74dc3cb..f0d4a38 100644
--- a/test_code/gdbscript
+++ b/test_code/gdbscript
@@ -6,6 +6,7 @@ add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/PeiC
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/PcdPeim.debug 0x7ee2240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/DxeIpl.debug 0x7edd240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/S3Resume2Pei.debug 0x7ed8240
+add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/CpuMpPei.debug
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/DxeCore.debug 0x7e8f240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/DevicePathDxe.debug 0x7553240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/PcdDxe.debug 0x754c240
@@ -17,6 +18,7 @@ add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/Runt
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/SecurityStubDxe.debug 0x7544240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/EbcDxe.debug 0x7538240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/CpuIo2Dxe.debug 0x7541240
+add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/CpuDxe.debug
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/IncompatiblePciDeviceSupportDxe.debug 0x7128240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/PciHotPlugInitDxe.debug 0x70fc240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/ResetSystemRuntimeDxe.debug 0x7ad3000
@@ -99,5 +101,4 @@ add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/UsbK
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/UsbMassStorageDxe.debug 0x6c96240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/QemuVideoDxe.debug 0x6c52240
add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/VirtioGpuDxe.debug 0x6c0a240
-add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/Shell.debug 0x6496240
-add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/HelloWorld.debug 0x65fd240
+add-symbol-file /home/koenigr/Memtest/git/edk2/Build/OvmfX64/DEBUG_GCC5/X64/Shell.debug 0x6449240