From: Ingo Molnar <mingo@elte.hu>
To: "Huang, Ying" <ying.huang@intel.com>
Cc: Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
Thomas Gleixner <tglx@linutronix.de>, Andi Kleen <ak@suse.de>,
Ian Campbell <ijc@hellion.org.uk>, Matt Mackall <mpm@selenic.com>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] x86 : relocate uninitialized variable in init DATA section into init BSS section
Date: Thu, 21 Feb 2008 10:53:01 +0100 [thread overview]
Message-ID: <20080221095301.GA29361@elte.hu> (raw)
In-Reply-To: <1203586106.4707.25.camel@caritas-dev.intel.com>
* Huang, Ying <ying.huang@intel.com> wrote:
> > > -int __initdata early_ioremap_debug;
> > > +int __initbss early_ioremap_debug;
> >
> > will we get some sort of build error if we accidentally do:
> >
> > int __initbss early_ioremap_debug = 1;
> >
> > ?
>
> I tested it just now, and there is no build error.
well, that's bad. We'd silently ignore the " = 1" and boot up with that
value at 0, right? At minimum we need some really prominent build-time
_errors_ (i.e. aborted builds) if this ever happens. But ideally,
shouldnt this whole thing be done at link time? Couldnt the linker sort
the variables that are zero initialized into the right section, and move
this constant maintenance pressure off the programmer's shoulder?
Ingo
next prev parent reply other threads:[~2008-02-21 9:53 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-21 8:15 [PATCH 2/2] x86 : relocate uninitialized variable in init DATA section into init BSS section Huang, Ying
2008-02-21 9:05 ` Ingo Molnar
2008-02-21 9:28 ` Huang, Ying
2008-02-21 9:53 ` Ingo Molnar [this message]
2008-02-21 12:18 ` Matt Mackall
2008-02-21 18:34 ` H. Peter Anvin
2008-02-22 2:38 ` Huang, Ying
2008-02-22 2:42 ` H. Peter Anvin
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=20080221095301.GA29361@elte.hu \
--to=mingo@elte.hu \
--cc=ak@suse.de \
--cc=hpa@zytor.com \
--cc=ijc@hellion.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=mpm@selenic.com \
--cc=tglx@linutronix.de \
--cc=ying.huang@intel.com \
/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