lkml.org 
[lkml]   [2009]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 1/6] x86, ftrace, hw-branch-tracer: support hotplug cpus
On Tue, 24 Feb 2009 20:36:22 +0100
Ingo Molnar <mingo@elte.hu> wrote:

>
> * Markus Metzger <markus.t.metzger@intel.com> wrote:
>
> > Support hotplug cpus.
>
> > +static int __cpuinit bts_hotcpu_handler(struct notifier_block *nfb,
> > + unsigned long action, void *hcpu)
> > +{
> > + unsigned int cpu = (unsigned long)hcpu;
> > +
> > + mutex_lock(&bts_tracer_mutex);
>
> This is buggy: CPU hotplug handlers must not sleep (they are
> called with irqs disabled)

I don't think that is the case; the cpu notifier chains are "raw", not
atomic, and the cpu hotplug core doesn't disable irqs while processing
the chains afaict. And there are several current examples of cpu
hotplug callbacks performing sleeping operations (slab and slub,
page_alloc, probably many others).



\
 
 \ /
  Last update: 2009-02-24 22:49    [W:0.065 / U:0.660 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site