Re: [PATCH 2/4] sched: implement __set_cpus_allowed()

From: Tejun Heo
Date: Mon May 31 2010 - 06:06:34 EST


On 05/31/2010 12:02 PM, Peter Zijlstra wrote:
> On Mon, 2010-05-31 at 12:01 +0200, Peter Zijlstra wrote:
>>> but we can update cpu_active mask before other
>>> CPU_UP_PREPARE notifiers are executed so that it's symmetrical to cpu
>>> down path and then this problem goes away the exact same way, right?
>>
>> Ah, no, we cannot mark it active before its actually up, because at that
>> time we'll actually try and run stuff on it, which clearly won't work
>> when its not there to run stuff.
>
> So we should clear it _before_ we go down, and set it _after_ we're up.
>

Yeah, sure, I misspoke. I meant CPU_ONLINE not CPU_UP_PREPARE. So,
we can mark a cpu active before other CPU_ONLINE callbacks are run.

Thanks.

--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/