From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: "Vincent Stehlé" <vincent.stehle@laposte.net>
Cc: linux-kernel@vger.kernel.org, linux-next@vger.kernel.org,
stable@vger.kernel.org
Subject: Re: [PATCH] topology: Fix compilation warning when not in SMP
Date: Fri, 4 Apr 2014 16:49:43 -0700 [thread overview]
Message-ID: <20140404234943.GA14633@kroah.com> (raw)
In-Reply-To: <1396593798-29173-1-git-send-email-vincent.stehle@laposte.net>
On Fri, Apr 04, 2014 at 08:43:18AM +0200, Vincent Stehlé wrote:
> The topology_##name() macro does not use its argument when CONFIG_SMP is not
> set, as it ultimately calls the cpu_data() macro.
>
> So we avoid maintaining a possibly unused `cpu' variable, to avoid the
> following compilation warning:
>
> drivers/base/topology.c: In function ‘show_physical_package_id’:
> drivers/base/topology.c:103:118: warning: unused variable ‘cpu’ [-Wunused-variable]
> define_id_show_func(physical_package_id);
>
> drivers/base/topology.c: In function ‘show_core_id’:
> drivers/base/topology.c:106:106: warning: unused variable ‘cpu’ [-Wunused-variable]
> define_id_show_func(core_id);
>
> This can be seen with e.g. x86 defconfig and CONFIG_SMP not set.
>
> Signed-off-by: Vincent Stehlé <vincent.stehle@laposte.net>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Cc: <stable@vger.kernel.org> # 3.10.x
> Cc: <stable@vger.kernel.org> # 3.13.x
> Cc: <stable@vger.kernel.org> # 3.14.x
Warnings aren't a stable kernel issue, so why would this be relevant
there?
thanks,
greg k-h
prev parent reply other threads:[~2014-04-04 23:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-04 6:43 [PATCH] topology: Fix compilation warning when not in SMP Vincent Stehlé
2014-04-04 23:49 ` Greg Kroah-Hartman [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=20140404234943.GA14633@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=vincent.stehle@laposte.net \
/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;
as well as URLs for NNTP newsgroup(s).