[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070310170819.GA26772@elte.hu>
Date: Sat, 10 Mar 2007 18:08:19 +0100
From: Ingo Molnar <mingo@...e.hu>
To: Nathan Lynch <ntl@...ox.com>
Cc: Cliff Wickman <cpw@....com>, linux-kernel@...r.kernel.org,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [PATCH 1/1] hotplug cpu: migrate a task within its cpuset
* Nathan Lynch <ntl@...ox.com> wrote:
> > > + /* try to stay on the same cpuset */
> > > + if (dest_cpu == NR_CPUS) {
> > > + p->cpus_allowed = cpuset_cpus_allowed(p);
> > > + dest_cpu = any_online_cpu(p->cpus_allowed);
> > > + }
> >
> > what's the practical effect of this - when moving the last CPU offline
> > from a node you got jobs migrated to really alien nodes? Thus i think we
> > should queue this up for v2.6.21 too, correct? It's a NOP on systems
> > that do not set up cpusets, so it's low-risk.
>
> See my earlier reply to this patch. Calling cpuset_cpus_allowed
> (which takes a mutex) here is a bug, since move_task_off_dead_cpu must
> be called with interrupts disabled.
ouch. i only checked the !CONFIG_CPUSET case :-/ It's a really bad idea
to have any locking there indeed. The name itself suggests some atomic
action.
Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists