lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 18 May 2011 10:31:53 +0800
From:	Yong Zhang <yong.zhang0@...il.com>
To:	Steven Rostedt <rostedt@...dmis.org>
Cc:	Hillf Danton <dhillf@...il.com>,
	LKML <linux-kernel@...r.kernel.org>, Ingo Molnar <mingo@...e.hu>,
	Peter Zijlstra <peterz@...radead.org>,
	Mike Galbraith <efault@....de>
Subject: Re: [PATCH] sched: correct how RT task is picked

On Wed, May 18, 2011 at 9:38 AM, Steven Rostedt <rostedt@...dmis.org> wrote:
>> I think you can take a look at next_prio(), it just calculate the
>> next highest task on the current cpu; in this case,
>> cpumask_test_cpu(cpu, &p->cpus_allowed) will be true for the most
>> of time, but maybe that task is bound to this cpu.
>
> I've been looking at the history here, and I think that '-1' is a relic.
>
> If you look at sched_rt.c in f65eda4f789168ba5ff3fa75546c29efeed19f58:
>
> $ git show f65eda4f:kernel/sched_rt.c
>
> You'll see that push_rt_task calls pick_next_highest_task_rt() with a
> -1. That code has long been replaced.

Yeah, the condition "cpu < 0" could be removed since we have no
that kind of caller.

>
> I'm a bit nervous about taking Hillf's patch as is. But a little more
> reviewing and testing may prove that it is legit.

But another point is like I said before:
'cpumask_test_cpu(cpu, &p->cpus_allowed)' doesn't equal to
'p->rt.nr_cpus_allowed > 1' because we could have bounded
task.
So the condition 'if (cpumask_test_cpu(cpu, &p->cpus_allowed))'
in Hillf's patch is not sufficient.

Thanks,
Yong



-- 
Only stand for myself
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ