linux-mips
[Top] [All Lists]

[PATCH 0/6] macros for section name cleanup

To: Sam Ravnborg <sam@ravnborg.org>
Subject: [PATCH 0/6] macros for section name cleanup
From: Tim Abbott <tabbott@MIT.EDU>
Date: Thu, 30 Apr 2009 15:32:30 -0400
Cc: Anders Kaseorg <andersk@mit.edu>, Waseem Daher <wdaher@mit.edu>, Denys Vlasenko <vda.linux@googlemail.com>, Jeff Arnold <jbarnold@mit.edu>, Benjamin Herrenschmidt <benh@kernel.crashing.org>, Bryan Wu <cooloney@kernel.org>, Chris Zankel <chris@zankel.net>, Cyrill Gorcunov <gorcunov@openvz.org>, David Howells <dhowells@redhat.com>, "David S. Miller" <davem@davemloft.net>, dev-etrax@axis.com, Geert Uytterhoeven <geert@linux-m68k.org>, Greg Ungerer <gerg@uclinux.org>, Haavard Skinnemoen <hskinnemoen@atmel.com>, Heiko Carstens <heiko.carstens@de.ibm.com>, Helge Deller <deller@gmx.de>, Hirokazu Takata <takata@linux-m32r.org>, "H. Peter Anvin" <hpa@zytor.com>, Ingo Molnar <mingo@redhat.com>, Jeff Dike <jdike@addtoit.com>, Jesper Nilsson <jesper.nilsson@axis.com>, Kyle McMartin <kyle@mcmartin.ca>, Linus Torvalds <torvalds@linux-foundation.org>, linux-alpha@vger.kernel.org, linux-am33-list@redhat.com, linux-arm-kernel@lists.arm.linux.org.uk, linux-ia64@vger.kernel.org, linux-m32r@ml.linux-m32r.org, linux-m68k@vger.kernel.org, linux-mips@linux-mips.org, linux-parisc@vger.kernel.org, linuxppc-dev@ozlabs.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org, Martin Schwidefsky <schwidefsky@de.ibm.com>, Michal Simek <monstr@monstr.eu>, microblaze-uclinux@itee.uq.edu.au, Mikael Starvik <starvik@axis.com>, Paul Mackerras <paulus@samba.org>, Paul Mundt <lethal@linux-sh.org>, Ralf Baechle <ralf@linux-mips.org>, Richard Henderson <rth@twiddle.net>, Roman Zippel <zippel@linux-m68k.org>, Russell King <rmk+kernel@arm.linux.org.uk>, sparclinux@vger.kernel.org, Thomas Gleixner <tglx@linutronix.de>, Tony Luck <tony.luck@intel.com>, uclinux-dist-devel@blackfin.uclinux.org, user-mode-linux-devel@lists.sourceforge.net, Yoshinori Sato <ysato@users.sourceforge.jp>, Tim Abbott <tabbott@mit.edu>
Original-recipient: rfc822;linux-mips@linux-mips.org
Sender: linux-mips-bounce@linux-mips.org
Here are the architecture-independent macro definitions needed for
to clean up the kernel's section names.  The overall diffstat from
this section name cleanup project is:

 96 files changed, 261 insertions(+), 503 deletions(-)

The decrease results from removing a lot of redundancy in the linker
scripts.

The long-term goal here is to add support for building the kernel with
-ffunction-sections -fdata-sections.  This requires renaming all the
magic section names in the kernel of the form .text.foo, .data.foo,
.bss.foo, and .rodata.foo to not have collisions with sections
generated for code like:

static int nosave = 0; /* -fdata-sections places in .data.nosave */
static void head(); /* -ffunction-sections places in .text.head */

Sam Ravnborg proposed that rather than just renaming all the sections
outright, we should start by first getting more control over the
section names used in the kernel so that we can later rename sections
without touching too many files.  These patch series implement that
cleanup.  Later, there will be another patch series to actually rename
the sections.

I'm hoping we can get just these macro definitions into 2.6.30 so that
the arch maintainers don't have to grab the macro definitions for
their trees while reviewing the patches for 2.6.31.

Shortly, I'm going to send one patch series for each of the
architectures updating those architectures to use these new macros
(and otherwise cleaning up section names on those architectures).

        -Tim Abbott

Tim Abbott (6):
  Add new macros for page-aligned data and bss sections.
  Add new NOSAVE_DATA linker script macro.
  Add new CACHELINE_ALIGNED_DATA linker script macro.
  Add new INIT_TASK_DATA() linker script macro.
  Add new READ_MOSTLY_DATA(align) linker script macro.
  Add support for __read_mostly to linux/cache.h

 include/asm-generic/vmlinux.lds.h |   27 +++++++++++++++++++++++++++
 include/linux/cache.h             |    6 ++++++
 include/linux/init_task.h         |    3 +++
 include/linux/linkage.h           |    9 +++++++++
 4 files changed, 45 insertions(+), 0 deletions(-)


<Prev in Thread] Current Thread [Next in Thread>