public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: David Mosberger <davidm@napali.hpl.hp.com>
To: linux-ia64@vger.kernel.org
Subject: Re: [PATCH] fix setting of sn_hub_info->shub_1_1_found
Date: Mon, 06 Jun 2005 17:25:09 +0000	[thread overview]
Message-ID: <17060.34549.590302.820704@napali.hpl.hp.com> (raw)
In-Reply-To: <42A04C38.mailxA351PB0RI@aqua.americas.sgi.com>

>>>>> On Mon, 06 Jun 2005 19:04:21 +0200, Andreas Schwab <schwab@suse.de> said:

  Andreas> David Mosberger <davidm@napali.hpl.hp.com> writes:
  >>>>>>> On Sat, 04 Jun 2005 14:18:16 +1000, Keith Owens <kaos@sgi.com> said:
  >>
  Keith> On Fri, 3 Jun 2005 11:50:55 -0700,
  Keith> "Luck, Tony" <tony.luck@intel.com> wrote:
  >> >>> This explains why XPC has been so troublesome to load on older systems.
  >> >>> Thanks Dean!
  >> >>>
  >> >>> Tony, can this still get into 2.6.12?
  >> >>
  >> >> Probably ... but the first hunk of the patch looks like a no-op,
  >> >> and contravenes some style guidlines about initializing global
  >> >> variables to 0.
  >> >>
  >> >> -static int shub_1_1_found __initdata;
  >> >> +static int __initdata shub_1_1_found = 0;
  >>
  Keith> There is a linker restriction that you must initialise variables that
  Keith> are to be stored in different sections, which is what __initdata does.
  Keith> without initialization shub_1_1_found ends up in .bss, with
  Keith> initialization it ends up in .init.data.

  >> Interesting.  Strikes me as a toolchain-bug, though.  Clearly the
  >> __initdata declaration is in conflict with putting the data in .bss,
  >> yet there is no warning or error.

  Andreas> Can't reproduce that with gcc 3.2, or anything newer.

  Andreas> $ cat section.c
  Andreas> int __attribute__((section(".init.data"))) foo;
  Andreas> $ gcc -S section.c
  Andreas> $ cat section.s
  Andreas> .file	"section.c"
  Andreas> .pred.safe_across_calls p1-p5,p16-p63
  Andreas> .global foo#
  Andreas> .section	.init.data,"aw",@progbits
  Andreas> .align 4
  Andreas> .type	foo#,@object
  Andreas> .size	foo#,4
  Andreas> foo:
  Andreas> .skip	4
  Andreas> .ident	"GCC: (GNU) 3.2.2"

I remembering GCC 3.x getting more picky about section conflicts.  So
perhaps these changes also fixed this particular issue.  Good.  I
guess it's time to declare the documentation officially out-of-date?

	--david

      parent reply	other threads:[~2005-06-06 17:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-03 12:25 [PATCH] fix setting of sn_hub_info->shub_1_1_found Dean Nelson
2005-06-03 13:58 ` Robin Holt
2005-06-03 18:50 ` Luck, Tony
2005-06-03 19:14 ` Dean Nelson
2005-06-03 19:36 ` Luck, Tony
2005-06-03 19:43 ` Dean Nelson
2005-06-03 19:57 ` Luck, Tony
2005-06-03 21:09 ` Russ Anderson
2005-06-03 21:21 ` David Mosberger
2005-06-04  4:18 ` Keith Owens
2005-06-06  5:05 ` Luck, Tony
2005-06-06 16:57 ` David Mosberger
2005-06-06 17:04 ` Andreas Schwab
2005-06-06 17:25 ` David Mosberger [this message]

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=17060.34549.590302.820704@napali.hpl.hp.com \
    --to=davidm@napali.hpl.hp.com \
    --cc=linux-ia64@vger.kernel.org \
    /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