From: Ingo Molnar <mingo@kernel.org>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Valentin Rothberg <valentinrothberg@gmail.com>,
akpm@linux-foundation.org, linux-kernel@vger.kernel.org,
Patrick Plagwitz <patrick.plagwitz@fau.de>,
Andreas Ziegler <ziegler@cs.fau.de>,
Daniel Lohmann <dl@cs.fau.de>
Subject: Re: kernel: stop_machine: report (un)dead code (and feedback request)
Date: Fri, 27 Nov 2015 08:42:24 +0100 [thread overview]
Message-ID: <20151127074224.GA23839@gmail.com> (raw)
In-Reply-To: <20151126145234.GL23362@nuc-i3427.alporthouse.com>
* Chris Wilson <chris@chris-wilson.co.uk> wrote:
> On Thu, Nov 26, 2015 at 03:45:59PM +0100, Valentin Rothberg wrote:
> > Hi Chris,
> >
> > your commit 4c477de14237 ("kernel: remove stop_machine() Kconfig
> > dependency") has shown up in today's linux-next tree (20151126).
> > The commit changes the #ifdef condition in kernel/stop_machine.c
> > from/to:
> >
> > -#if defined(CONFIG_STOP_MACHINE) && defined(CONFIG_SMP)
> > +#if defined(CONFIG_SMP) || defined(CONFIG_HOTPLUG_CPU)
> >
> > Although this change fixes certain configs on X86, the condition now is
> > a tautology since CONFIG_SMP is already required to compile the file:
> >
> > kernel/Makefile:65:obj-$(CONFIG_SMP) += stop_machine.o
> >
> > AFAIU, we can safely remove this #ifdef?
>
> That seems logical. The argument in favour of it would be to keep the
> ifdeffery around the function defintion the same as the function
> declaration in stop_machine.h.
But this would introduce a bit of fragility: we could re-introduce the same
regression that the commit fixes, if we ever changed the SMP dependency for
stop_machine.c.
Thanks,
Ingo
prev parent reply other threads:[~2015-11-27 7:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-26 14:45 kernel: stop_machine: report (un)dead code (and feedback request) Valentin Rothberg
2015-11-26 14:52 ` Chris Wilson
2015-11-27 7:42 ` Ingo Molnar [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=20151127074224.GA23839@gmail.com \
--to=mingo@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=chris@chris-wilson.co.uk \
--cc=dl@cs.fau.de \
--cc=linux-kernel@vger.kernel.org \
--cc=patrick.plagwitz@fau.de \
--cc=valentinrothberg@gmail.com \
--cc=ziegler@cs.fau.de \
/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.