From: "Christoph Egger" <Christoph.Egger@amd.com>
To: xen-devel@lists.xensource.com
Cc: Keir Fraser <Keir.Fraser@xensource.com>
Subject: [PATCH][ELF] Correct space calculation for symtab when BSD_SYMTAB=yes
Date: Thu, 2 Aug 2007 10:03:53 +0200 [thread overview]
Message-ID: <200708021003.54137.Christoph.Egger@amd.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 892 bytes --]
Hi!
If there is a string table for section headers, it also gets loaded.
Therefore take it into account in size calculation for kernel symtab.
Also there is no need to call elf_set_verbose() a second time
after elf_init() (First call happens within elf_init()).
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Keir: Can you also apply changeset 15672 and this patch
to Xen 3.1-stable, since these fixes an regression for Xen 3.1, please?
--
AMD Saxony, Dresden, Germany
Operating System Research Center
Legal Information:
AMD Saxony Limited Liability Company & Co. KG
Sitz (Geschäftsanschrift):
Wilschdorfer Landstr. 101, 01109 Dresden, Deutschland
Registergericht Dresden: HRA 4896
vertretungsberechtigter Komplementär:
AMD Saxony LLC (Sitz Wilmington, Delaware, USA)
Geschäftsführer der AMD Saxony LLC:
Dr. Hans-R. Deppe, Thomas McCoy
[-- Attachment #2: xen_symtab.diff --]
[-- Type: text/x-diff, Size: 1106 bytes --]
diff -r 88bb0d305308 xen/arch/x86/domain_build.c
--- a/xen/arch/x86/domain_build.c Wed Aug 01 15:47:54 2007 +0100
+++ b/xen/arch/x86/domain_build.c Thu Aug 02 09:31:58 2007 +0200
@@ -268,9 +268,6 @@ int __init construct_dom0(
if ( (rc = elf_init(&elf, image_start, image_len)) != 0 )
return rc;
-#ifdef VERBOSE
- elf_set_verbose(&elf);
-#endif
elf_parse_binary(&elf);
if ( (rc = elf_xen_parse(&elf, &parms)) != 0 )
return rc;
diff -r 88bb0d305308 xen/common/libelf/libelf-loader.c
--- a/xen/common/libelf/libelf-loader.c Wed Aug 01 15:47:54 2007 +0100
+++ b/xen/common/libelf/libelf-loader.c Thu Aug 02 09:30:52 2007 +0200
@@ -53,8 +53,10 @@ int elf_init(struct elf_binary *elf, con
/* Find section string table. */
section = elf_uval(elf, elf->ehdr, e_shstrndx);
shdr = elf_shdr_by_index(elf, section);
- if ( shdr != NULL )
+ if ( shdr != NULL ) {
elf->sec_strtab = elf_section_start(elf, shdr);
+ high = low = (unsigned long)shdr;
+ }
/* Find symbol table and symbol string table. */
count = elf_shdr_count(elf);
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
next reply other threads:[~2007-08-02 8:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-02 8:03 Christoph Egger [this message]
2007-08-02 8:49 ` [PATCH][ELF] Correct space calculation for symtab when BSD_SYMTAB=yes Keir Fraser
2007-08-02 12:26 ` Christoph Egger
2007-08-02 13:21 ` Keir Fraser
2007-08-02 16:52 ` Christoph Egger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200708021003.54137.Christoph.Egger@amd.com \
--to=christoph.egger@amd.com \
--cc=Keir.Fraser@xensource.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.