[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200709112107.53155.vda.linux@googlemail.com>
Date: Tue, 11 Sep 2007 21:07:53 +0100
From: Denys Vlasenko <vda.linux@...glemail.com>
To: Sam Ravnborg <sam@...nborg.org>
Cc: linux-kernel@...r.kernel.org
Subject: [PATCH 1/4] build system: section garbage collection for vmlinux
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@...glemail.com>
--
vda
Download attachment "linux-2.6.23-rc4.0.fixname.sh" of type "application/x-shellscript" (1061 bytes)
Download attachment "linux-2.6.23-rc4.1.fixname.patch.bz2" of type "application/x-bzip2" (14440 bytes)
Powered by blists - more mailing lists