All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH][URGENT] kernel/vmlinux.lds.S: Handle note sections
@ 2007-10-01 12:24 Maciej W. Rozycki
  2007-10-01 13:11 ` Ralf Baechle
  0 siblings, 1 reply; 2+ messages in thread
From: Maciej W. Rozycki @ 2007-10-01 12:24 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: linux-mips

 Store any note sections after the exception tables like the other 
architectures do.  This is required for .note.gnu.build-id emitted from 
binutils 2.18 onwards if nothing else.

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
---
Ralf,

 Without it a binary with a layout like this is created:

$ readelf -l vmlinux

Elf file type is EXEC (Executable file)
Entry point 0xffffffff804cc000
There are 3 program headers, starting at offset 64

Program Headers:
  Type           Offset             VirtAddr           PhysAddr
                 FileSiz            MemSiz              Flags  Align
  LOAD           0x00000000000000e8 0x0000000000000000 0x0000000000000000
                 0x0000000000000024 0x0000000000000024  R      4
  LOAD           0x0000000000004000 0xffffffff80040000 0xffffffff80040000
                 0x00000000004bead8 0x0000000000642980  RWE    4000
  NOTE           0x00000000000000e8 0x0000000000000000 0x0000000000000000
                 0x0000000000000024 0x0000000000000024  R      4

 Section to Segment mapping:
  Segment Sections...
   00     .note.gnu.build-id 
   01     .text __ex_table __dbe_table .rodata __ksymtab __ksymtab_gpl __ksymtab_strings __param .data .data.cacheline_aligned .init.text .init.data .init.setup .initcall.init .con_initcall.init .exit.text .bss 
   02     .note.gnu.build-id 

which does not quite work as the first segment is in the KUSEG.

 Please apply ASAP.

  Maciej

patch-mips-2.6.23-rc5-20070904-mips-notes-0
diff -up --recursive --new-file linux-mips-2.6.23-rc5-20070904.macro/arch/mips/kernel/vmlinux.lds.S linux-mips-2.6.23-rc5-20070904/arch/mips/kernel/vmlinux.lds.S
--- linux-mips-2.6.23-rc5-20070904.macro/arch/mips/kernel/vmlinux.lds.S	2007-09-04 04:55:19.000000000 +0000
+++ linux-mips-2.6.23-rc5-20070904/arch/mips/kernel/vmlinux.lds.S	2007-10-01 04:16:44.000000000 +0000
@@ -45,6 +45,8 @@ SECTIONS
   __dbe_table : { *(__dbe_table) }
   __stop___dbe_table = .;
 
+  NOTES
+
   RODATA
 
   /* writeable */

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH][URGENT] kernel/vmlinux.lds.S: Handle note sections
  2007-10-01 12:24 [PATCH][URGENT] kernel/vmlinux.lds.S: Handle note sections Maciej W. Rozycki
@ 2007-10-01 13:11 ` Ralf Baechle
  0 siblings, 0 replies; 2+ messages in thread
From: Ralf Baechle @ 2007-10-01 13:11 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: linux-mips

On Mon, Oct 01, 2007 at 01:24:04PM +0100, Maciej W. Rozycki wrote:

>  Store any note sections after the exception tables like the other 
> architectures do.  This is required for .note.gnu.build-id emitted from 
> binutils 2.18 onwards if nothing else.

Thanks for looking into this.  I knew the problem but didn't get around
to looking into it yet ...

Patch applied.

  Ralf

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-10-01 13:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-01 12:24 [PATCH][URGENT] kernel/vmlinux.lds.S: Handle note sections Maciej W. Rozycki
2007-10-01 13:11 ` Ralf Baechle

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.