* [PATCH] fix bug in scripts/kallsyms.c
@ 2002-12-21 18:05 James Bottomley
0 siblings, 0 replies; only message in thread
From: James Bottomley @ 2002-12-21 18:05 UTC (permalink / raw
To: Kai Germaschewski; +Cc: linux-kernel, James.Bottomley
[-- Attachment #1: Type: text/plain, Size: 411 bytes --]
kallsyms.c generates the symbol table in a .S file using the assembler .string
macro. Unfortunately, the .string macro is implemented in a platform specific
way (it may or may not zero terminate the string). On parisc, it doesn't zero
terminate, so the symbol table search doesn't work.
The solution is to replace .string with .asciz which is guaranteed to do the
correct thing on all platforms.
James
[-- Attachment #2: tmp.diff --]
[-- Type: text/plain , Size: 368 bytes --]
===== scripts/kallsyms.c 1.2 vs edited =====
--- 1.2/scripts/kallsyms.c Thu Dec 5 13:57:11 2002
+++ edited/scripts/kallsyms.c Sat Dec 21 11:43:11 2002
@@ -128,7 +128,7 @@
if (table[i].addr == last_addr)
continue;
- printf("\t.string\t\"%s\"\n", table[i].sym);
+ printf("\t.asciz\t\"%s\"\n", table[i].sym);
last_addr = table[i].addr;
}
printf("\n");
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-12-21 17:57 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-12-21 18:05 [PATCH] fix bug in scripts/kallsyms.c James Bottomley
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).