From: Andrew Morton <akpm@linux-foundation.org>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Peter Zijlstra <peterz@infradead.org>,
Thomas Gleixner <tglx@linutronix.de>,
Linus Torvalds <torvalds@linux-foundation.org>,
Ingo Molnar <mingo@elte.hu>, "H. Peter Anvin" <hpa@zytor.com>,
linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
Stephen Rothwell <sfr@canb.auug.org.au>
Subject: Re: [PATCH] sched: Fix unused variable warning on UP (was: Re: linux-next: tip tree build warning)
Date: Mon, 8 Feb 2010 00:32:41 -0800 [thread overview]
Message-ID: <20100208003241.1155a7e5.akpm@linux-foundation.org> (raw)
In-Reply-To: <10f740e81002071231j6977c6c7ie3f9e82bd0170f21@mail.gmail.com>
On Sun, 7 Feb 2010 21:31:56 +0100 Geert Uytterhoeven <geert@linux-m68k.org> wrote:
> Shouldn't put_cpu() take a (possibly dummy) `cpu' parameter, as
> returned by get_cpu()?
Yeah, that always seemed a bit screwy. Something like this...
--- a/include/linux/smp.h~a
+++ a/include/linux/smp.h
@@ -177,6 +177,15 @@ smp_call_function_any(const struct cpuma
#define put_cpu() preempt_enable()
/*
+ * This just exists to touch the `cpu' arg, to suppress unused var
+ * warnings
+ */
+static inline void put_cpu_nr(unsigned cpu)
+{
+ put_cpu();
+}
+
+/*
* Callback to arch code if there's nosmp or maxcpus=0 on the
* boot command line:
*/
_
next prev parent reply other threads:[~2010-02-08 8:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-07 19:57 [PATCH] sched: Fix unused variable warning on UP (was: Re: linux-next: tip tree build warning) Geert Uytterhoeven
2010-02-07 19:58 ` Peter Zijlstra
2010-02-07 20:26 ` Geert Uytterhoeven
2010-02-07 20:31 ` Geert Uytterhoeven
2010-02-08 8:32 ` Andrew Morton [this message]
2010-02-08 9:47 ` 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=20100208003241.1155a7e5.akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=geert@linux-m68k.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=sfr@canb.auug.org.au \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.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