public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: KY Srinivasan <kys@microsoft.com>
Cc: "gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"devel@linuxdriverproject.org" <devel@linuxdriverproject.org>,
	"mingo@kernel.org" <mingo@kernel.org>,
	"rafael.j.wysocki@intel.com" <rafael.j.wysocki@intel.com>,
	"tglx@linutronix.de" <tglx@linutronix.de>,
	Vitaly Kuznetsov <vkuznets@redhat.com>
Subject: Re: [PATCH  1/1] cpu-hotplug: export cpu_hotplug_enable/cpu_hotplug_disable
Date: Tue, 23 Jun 2015 20:13:10 +0200	[thread overview]
Message-ID: <20150623181310.GG3644@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <BY2PR0301MB16541403929BC684018DE59FA0A00@BY2PR0301MB1654.namprd03.prod.outlook.com>

On Tue, Jun 23, 2015 at 04:57:05PM +0000, KY Srinivasan wrote:

> > diff --git a/kernel/cpu.c b/kernel/cpu.c
> > index 94bbe46..8f35ee6 100644
> > --- a/kernel/cpu.c
> > +++ b/kernel/cpu.c
> > @@ -190,17 +190,19 @@ void cpu_hotplug_done(void)
> >  void cpu_hotplug_disable(void)
> >  {
> >  	cpu_maps_update_begin();
> > -	cpu_hotplug_disabled = 1;
> > +	cpu_hotplug_disabled++;
> >  	cpu_maps_update_done();
> >  }
> > +EXPORT_SYMBOL_GPL(cpu_hotplug_disable);
> > 
> >  void cpu_hotplug_enable(void)
> >  {
> >  	cpu_maps_update_begin();
> > -	cpu_hotplug_disabled = 0;
> > +	if (cpu_hotplug_disabled)
> > +		cpu_hotplug_disabled--;

No that just papers over bugs.

> >  	cpu_maps_update_done();
> >  }

  reply	other threads:[~2015-06-23 18:13 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-22  2:56 [PATCH 1/1] cpu-hotplug: export cpu_hotplug_enable/cpu_hotplug_disable K. Y. Srinivasan
2015-06-23 16:57 ` KY Srinivasan
2015-06-23 18:13   ` Peter Zijlstra [this message]
2015-06-24  9:43     ` Vitaly Kuznetsov
2015-06-24  9:54       ` Thomas Gleixner
2015-06-24 11:11         ` Vitaly Kuznetsov
2015-06-24 10:27       ` Peter Zijlstra
2015-06-24 11:14         ` Vitaly Kuznetsov

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=20150623181310.GG3644@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=devel@linuxdriverproject.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=kys@microsoft.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=rafael.j.wysocki@intel.com \
    --cc=tglx@linutronix.de \
    --cc=vkuznets@redhat.com \
    /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