From: Rusty Russell <rusty@rustcorp.com.au>
To: Chris Meadors <clubneon@hereintown.net>
Cc: linux-kernel@vger.kernel.org, akpm@zip.com.au, trivial@rustcorp.com.au
Subject: Re: GCC 3.4 Heads-up
Date: Tue, 30 Dec 2003 12:37:18 +1100 [thread overview]
Message-ID: <20031230123718.504d08b0.rusty@rustcorp.com.au> (raw)
In-Reply-To: <1072403207.17036.37.camel@clubneon.clubneon.com>
On Thu, 25 Dec 2003 20:46:48 -0500
Chris Meadors <clubneon@hereintown.net> wrote:
> I know it isn't the recommended compiler, heck it isn't even released
> yet, but I was messing around with a GCC 3.4 snapshot, and figured I'd
> give compiling the 2.6.0 kernel a shot.
>
> Other than the constant barrage of warnings about the use of compound
> expressions as lvalues being deprecated* (mostly because of lines 114,
> 116, and 117 of rcupdate.h, which is included everywhere), the build
> goes very well.
Thanks, downloaded this and tried it. It's complaining about:
#define per_cpu(var, cpu) ((void)cpu, per_cpu__##var)
There are several ways of fixing this, but the simplest is:
#define per_cpu(var, cpu) (*((void)cpu, &per_cpu__##var))
Cheers,
Rusty.
--
there are those who do and those who hang on and you don't see too
many doers quoting their contemporaries. -- Larry McVoy
diff -urpN --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.6.0/include/asm-generic/percpu.h working-2.6.0-new-gcc/include/asm-generic/percpu.h
--- linux-2.6.0/include/asm-generic/percpu.h 2003-09-22 10:26:12.000000000 +1000
+++ working-2.6.0-new-gcc/include/asm-generic/percpu.h 2003-12-30 12:35:20.000000000 +1100
@@ -29,7 +29,7 @@ do { \
#define DEFINE_PER_CPU(type, name) \
__typeof__(type) per_cpu__##name
-#define per_cpu(var, cpu) ((void)cpu, per_cpu__##var)
+#define per_cpu(var, cpu) (*((void)cpu, &per_cpu__##var))
#define __get_cpu_var(var) per_cpu__##var
#endif /* SMP */
next prev parent reply other threads:[~2003-12-30 2:06 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-26 1:46 GCC 3.4 Heads-up Chris Meadors
2003-12-26 3:46 ` H. Peter Anvin
2003-12-26 4:34 ` Linus Torvalds
2003-12-26 6:04 ` H. Peter Anvin
2003-12-26 6:58 ` Andy Isaacson
2003-12-26 7:07 ` H. Peter Anvin
2003-12-26 7:08 ` Linus Torvalds
2003-12-29 16:13 ` David Lloyd
2004-01-02 21:57 ` Bill Davidsen
2004-01-03 21:11 ` Krzysztof Halasa
2004-01-04 5:48 ` Bill Davidsen
2004-01-04 20:41 ` Linus Torvalds
2004-01-05 1:28 ` Bill Davidsen
2004-01-05 1:38 ` Måns Rullgård
2004-01-05 23:49 ` Ingo Oeser
2004-01-05 2:25 ` Linus Torvalds
2004-01-05 4:15 ` Bill Davidsen
2004-01-05 4:36 ` Linus Torvalds
2003-12-30 1:37 ` Rusty Russell [this message]
-- strict thread matches above, loose matches on Subject: below --
2003-12-26 11:02 linux
2003-12-26 20:05 ` Linus Torvalds
2003-12-27 16:39 ` Andreas Schwab
[not found] <16PqK-8eK-1@gated-at.bofh.it>
[not found] ` <16RiU-2kO-1@gated-at.bofh.it>
[not found] ` <16S5h-3no-5@gated-at.bofh.it>
2004-01-06 21:06 ` David Mosberger-Tang
2004-01-06 22:33 ` Richard Henderson
2004-01-06 23:23 ` Linus Torvalds
2004-01-07 9:54 ` Richard Henderson
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=20031230123718.504d08b0.rusty@rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=akpm@zip.com.au \
--cc=clubneon@hereintown.net \
--cc=linux-kernel@vger.kernel.org \
--cc=trivial@rustcorp.com.au \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.