lkml.org 
[lkml]   [2007]   [Sep]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH 1/4] build system: section garbage collection for vmlinux
Date
This patch is needed for --gc-sections to work, regardless
of which final form that support will have.

This patch renames .text.xxx and .data.xxx sections
into .xxx.text and .xxx.data, respectively.

.bss.page_aligned (the only .bss.xxx -like section we have)
is renamed .bss.k.page_aligned. ".page_aligned.bss"
wouldn't work - gcc will assign such section attributes
which make it unmergeable with .bss. In fact, binutils ld
had a bug and instead of complaining was producing
broken vmlinux. The bug is fixed in binutils. Amazingly
fast reaction from binutils folks to bug reports! Thanks!

.bss.k.page_aligned is more-or-less ok, since it cannot collide
with gcc-produced sections due to second dot in the name. However,
should we want to do this in linker script:

.bss : { *(.bss) *(.bss.*) *(.bss.k.page_aligned))

it wouldn't work. But currently we don't need that.

If patch doesn't apply to a newer kernel,
you can regenerate it by running linux-2.6.23-rc4.0.fixname.sh
in a kernel free and rediffing it against unmodified one.

Please apply.

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
--
vda
[unhandled content-type:application/x-shellscript][unhandled content-type:application/x-bzip2]
\
 
 \ /
  Last update: 2007-09-11 22:19    [W:0.076 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site