Messages in this thread | | | Date | Sat, 10 Mar 2007 18:08:19 +0100 | From | Ingo Molnar <> | Subject | Re: [PATCH 1/1] hotplug cpu: migrate a task within its cpuset |
| |
* Nathan Lynch <ntl@pobox.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@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |