[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 3/8] gdb: Do not lazy load module symbols
From: |
Glenn Washburn |
Subject: |
[PATCH 3/8] gdb: Do not lazy load module symbols |
Date: |
Sun, 13 Feb 2022 21:42:40 -0600 |
When loading module symbols, tell GDB to load them all right away. GDB by
default will lazy load symbols as needed in the background. However, this
process will output to GDB's stdout some messages. This fixes a bug where
output from the loading process gets printed to the .segments.tmp file
causing gmodule.pl to write a bad .loadsym.gdb that GDB chokes on.
Signed-off-by: Glenn Washburn <development@efficientek.com>
---
grub-core/gmodule.pl.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grub-core/gmodule.pl.in b/grub-core/gmodule.pl.in
index 78aa1e64e..c74eedf4a 100644
--- a/grub-core/gmodule.pl.in
+++ b/grub-core/gmodule.pl.in
@@ -11,7 +11,7 @@ use strict;
while (<>) {
my ($name, %sections) = split;
- print "add-symbol-file $name.module";
+ print "add-symbol-file -readnow $name.module";
open (READELF, "readelf -S $name.mod |") or die;
while (<READELF>) {
--
2.27.0
- [PATCH 0/8] GDB script fixes and improvements, Glenn Washburn, 2022/02/13
- [PATCH 1/8] gdb: Move runtime module loading into runtime_load_module, Glenn Washburn, 2022/02/13
- [PATCH 2/8] gdb: If no modules have been loaded, do not try to load module symbols, Glenn Washburn, 2022/02/13
- [PATCH 3/8] gdb: Do not lazy load module symbols,
Glenn Washburn <=
- [PATCH 4/8] gdb: Prevent wrapping when writing to .segments.tmp, Glenn Washburn, 2022/02/13
- [PATCH 5/8] gdb: Add functions to make loading from dynamically positioned targets easier, Glenn Washburn, 2022/02/13
- [PATCH 6/8] gdb: If enabled, print line used to load EFI kernel symbols when using gdb_grub script, Glenn Washburn, 2022/02/13
- [PATCH 7/8] gdb: Conditionally run GDB script logic for dynamically or statically positioned GRUB, Glenn Washburn, 2022/02/13
- [PATCH 8/8] gdb: Get correct mod variable value, Glenn Washburn, 2022/02/13