RFC: fix misplaced .note.gnu.build-id section

Johannes Stezenbach js at sig21.net
Fri May 21 16:22:55 EDT 2010


On Fri, May 21, 2010 at 07:43:39PM +0100, Russell King - ARM Linux wrote:
> On Fri, May 21, 2010 at 03:36:12PM +0200, Johannes Stezenbach wrote:
> > when building with a binutils version which supports --build-id
> > the .note.gnu.build-id section is placed at address 0 in the
> > resulting vmlinux ELF file:
> > 
> > Program Header:
> >     LOAD off    0x00008000 vaddr 0x00000000 paddr 0x00000000 align 2**15
> >          filesz 0x00000024 memsz 0x00000024 flags r--
> >     LOAD off    0x00010000 vaddr 0xc0008000 paddr 0xc0008000 align 2**15
> >          filesz 0x0033cb60 memsz 0x0036df04 flags rwx
> >     NOTE off    0x00008000 vaddr 0x00000000 paddr 0x00000000 align 2**2
> >          filesz 0x00000024 memsz 0x00000024 flags r--
> 
> There seems to be little reason for the note to be loaded into memory -
> maybe the right fix is to ensure that the note doesn't get placed into
> a loadable output section.

That's what I thought, too.  But it seems x86 explicitly
puts NOTES into both :text and :note.  Maybe the intention
is that the build-id is contained in crash dump images?
But I'm not sure if this is of relevance for ARM, it
would indeed be easier to just discard .note.gnu.build-id.
Shall I prepare a patch to do that?

Thanks,
Johannes



More information about the linux-arm-kernel mailing list