public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Tim Abbott <tabbott@MIT.EDU>
Cc: andi@firstfloor.org, jbarnold@MIT.EDU,
	linux-kernel@vger.kernel.org, vda.linux@googlemail.com,
	andersk@MIT.EDU, wdaher@MIT.EDU, knikanth@suse.de
Subject: Re: [PATCH 1/7] Make section names compatible with -ffunction-sections -fdata-sections
Date: Mon, 12 Jan 2009 13:51:27 -0800	[thread overview]
Message-ID: <20090112135127.7a0bb392.akpm@linux-foundation.org> (raw)
In-Reply-To: <alpine.DEB.2.00.0901011725320.10164@vinegar-pot.mit.edu>

On Sun, 4 Jan 2009 14:20:35 -0500 (EST)
Tim Abbott <tabbott@MIT.EDU> wrote:

> On Thu, 1 Jan 2009, Andrew Morton wrote:
> 
> > OK, it hits a lot of files in minor ways.
> >
> > You could ask Linus to merge it late in the -rc1 merge window (please
> > cc me on the email).  Or you could just send it to me (with the usual
> > cc's) and I'll toss it into my 2.6.29-rc1 pile.  I doubt if it'll cause
> > much trouble.  But please do check its applicability to linux-next - people
> > have been moving arch files into different directories lately.
> 
> Andrew,
> 
> I've attached for you a version of the patch the applies to current 
> linux-next (next-20090102).
> 
> It does not apply to Linus' current master because d3794979a in linux-next 
> adds use of the ".data.percpu.first" section name, which this patch 
> updates to ".kernel.data.percpu.first".  I think it'll be easiest to just 
> merge this after d3794979a.
> 
> If a version of d3794979a is not going to be merged first, there will be 
> two merge conflicts that are easy to resolve as they are changes to code 
> added by d3794979a, but we'll then need to fix d3794979a before merging 
> d3794979a.
> 

I don't think anyone will want to carry this in a non-mainline tree for
any amount of time.  it'd be best to squeeze it into mainline pretty
much immediately.  But...

> This patch was originally written by Denys Vlasenko, but it has been
> substantially modified by Anders Kaseorg and Tim Abbott to update it
> to apply to the current kernel and fix bugs.  Any bugs were added by
> Anders Kaseorg and Tim Abbott.
> 
> The purpose of this patch is to make it possible to build the kernel
> with "gcc -ffunction-sections -fdata-sections".
> 
> The problem is that with -ffunction-sections -fdata-sections, gcc
> creates sections like .text.head and .data.nosave whenever someone has
> innocuous code like this:
> 
> static void head(...) {...}
> 
> or this:
> 
> static int nosave = 1;
> 
> somewhere in the kernel.
> 
> The kernel linker scripts are confused by such names, and thus put
> these sections in the wrong places.
> 
> This patch renames all "magic" section names used by the kernel to not
> have this format, eliminating the possibility of such collisions.
> 
> Ksplice's 'run-pre matching' process is much simpler if the original
> kernel was compiled with -ffunction-sections and -fdata-sections.
> 

The changelog gives us no reason to do that.

So we `make it possible to build the kernel > with "gcc
-ffunction-sections -fdata-sections"'.  So what?  Where is the value in
that?


  reply	other threads:[~2009-01-12 21:52 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-06  0:03 [PATCH 0/7] Ksplice: Rebootless kernel updates Jeff Arnold
2008-12-06  0:03 ` [PATCH 1/7] Make section names compatible with -ffunction-sections -fdata-sections Jeff Arnold
2008-12-06  0:03   ` [PATCH 2/7] x86: Add an option to compile " Jeff Arnold
2008-12-06  0:03     ` [PATCH 3/7] Ksplice: Make find_symbol return a struct kernel_symbol Jeff Arnold
2008-12-06  0:03       ` [PATCH 4/7] Ksplice: Add module_data_address (the analogue of module_text_address) Jeff Arnold
2008-12-06  0:03         ` [PATCH 5/7] Ksplice: Add functions for walking kallsyms symbols Jeff Arnold
2008-12-06  0:03           ` [PATCH 6/7] Ksplice: Export symbols needed for Ksplice Jeff Arnold
2008-12-06  0:04             ` [PATCH 7/7] Ksplice: Support updating x86-32 and x86-64 Jeff Arnold
2008-12-17  5:41               ` Theodore Tso
2008-12-18  2:09                 ` Tim Abbott
2009-02-07  2:36               ` Rusty Russell
2009-02-10  1:01                 ` Tim Abbott
2009-02-04 11:35             ` [PATCH 6/7] Ksplice: Export symbols needed for Ksplice Rusty Russell
2009-02-13  1:46               ` Tim Abbott
2009-02-16  7:11                 ` Rusty Russell
2009-02-04 11:30           ` [PATCH 5/7] Ksplice: Add functions for walking kallsyms symbols Rusty Russell
2009-02-04 21:31             ` Anders Kaseorg
2009-02-04 11:21         ` [PATCH 4/7] Ksplice: Add module_data_address (the analogue of module_text_address) Rusty Russell
2009-02-04 20:48           ` Anders Kaseorg
2009-02-07 12:45             ` Rusty Russell
2009-02-04  9:26       ` [PATCH 3/7] Ksplice: Make find_symbol return a struct kernel_symbol Rusty Russell
2009-02-04  8:38     ` [PATCH 2/7] x86: Add an option to compile with -ffunction-sections -fdata-sections Rusty Russell
2009-02-04 10:26       ` Anders Kaseorg
2009-02-04 10:58         ` Rusty Russell
2009-02-04 20:50           ` Anders Kaseorg
2008-12-06  8:46   ` [PATCH 1/7] Make section names compatible " Andi Kleen
2008-12-31 19:18     ` Tim Abbott
2008-12-31 19:52       ` Andi Kleen
2008-12-31 21:59         ` Tim Abbott
2009-01-01 16:32           ` Andrew Morton
2009-01-04 19:20             ` Tim Abbott
2009-01-12 21:51               ` Andrew Morton [this message]
2009-01-12 22:11                 ` Andi Kleen
2009-02-04  8:15   ` Rusty Russell
2009-02-05  1:11     ` Anders Kaseorg
2009-02-05  2:00       ` Anders Kaseorg
2008-12-17  2:48 ` [PATCH 0/7] Ksplice: Rebootless kernel updates Tim Abbott
2008-12-17  3:07   ` Andrew Morton
2008-12-17  3:53     ` Dave Jones
2008-12-17 17:19       ` Jeff Arnold
2008-12-17  5:05     ` Tim Abbott
2008-12-17 12:09       ` Ben Collins
2008-12-17 12:06     ` Ben Collins

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090112135127.7a0bb392.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=andersk@MIT.EDU \
    --cc=andi@firstfloor.org \
    --cc=jbarnold@MIT.EDU \
    --cc=knikanth@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tabbott@MIT.EDU \
    --cc=vda.linux@googlemail.com \
    --cc=wdaher@MIT.EDU \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox