Re: [PATCH RESEND v10] sched/deadline: support dl task migration during cpu hotplug

From: Juri Lelli
Date: Tue Mar 24 2015 - 05:27:19 EST


Hi,

On 23/03/2015 08:55, Peter Zijlstra wrote:
> On Mon, Mar 23, 2015 at 08:25:04AM +0100, Ingo Molnar wrote:
>>>>>>>>> + if (cpu >= nr_cpu_ids) {
>>>>>>>>> + if (dl_bandwidth_enabled()) {
>>>>>>>>> + /*
>>>>>>>>> + * Fail to find any suitable cpu.
>>>>>>>>> + * The task will never come back!
>>>>>>>>> + */
>>>>>>>>> + WARN_ON(1);
>>>>>>>>
>>>>>>>> Can this condition happen to users with a non-buggy kernel?
>
>> I still haven't seen a satisfactory answer to this question. Please
>> don't resend patches without clearing questions raised during review.
>
> So I had a look on Friday, it _should_ not happen, but it does due to a
> second bug Juri is currently chasing down.
>

Right, it should not happen. It happens because hotplug operations are
destructive w.r.t. cpusets. Peter, how about we move the check you put
in sched_cpu_inactive() to cpuset_cpu_inactive()? This way, if we fail,
we don't need to destroy/rebuild the domains.

Thanks,

- Juri