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:	Sun, 9 Jun 2013 17:59:42 +0800
From:	Zhao Chenhui <chenhui.zhao@...escale.com>
To:	Sebastian Andrzej Siewior <bigeasy@...utronix.de>
CC:	<linux-rt-users@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	<tglx@...utronix.de>, <leoli@...escale.com>,
	<scottwood@...escale.com>, <Priyanka.Jain@...escale.com>
Subject: Re: [PATCH][RFC] kernel/cpu: do not change the cpus_allowed of the
 current task when unplugging cpus

On Fri, Jun 07, 2013 at 11:05:43AM +0200, Sebastian Andrzej Siewior wrote:
> * Zhao Chenhui | 2013-05-16 18:17:19 [+0800]:
> 
> >We found a problem. When a cpu is brought down using _cpu_down(),
> >the corresponding cpu bit in the cpus_allowed of the current task is
> >cleared. But this bit will not be set when the same cpu is online again.
> >Then, the current task and its child processes will not be allowed to
> >run on this cpu.
> 
> Isn't this what should happen? This also happens on mainline if you
> leave the RT bits out, right? You should be able to put the task back on
> the CPU once the CPU is up again.
> 
> Sebastian
> 

No. _cpu_down() on mainline do not change the cpus_allowed.

The problem is that the task which turned off cpu2 (for instance)
can not run on cpu2 again after cpu2 is turned on, because cpu2 has been
removed from the cpus_allowed of the task.

The task can put himself back on cpu2 throuhg the system call,
but I think applications should not do this work and do not care which cpu
it is running on in most time.

-Chenhui

--
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