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:	Thu, 09 Feb 2012 14:12:17 +0530
From:	"Srivatsa S. Bhat" <srivatsa.bhat@...ux.vnet.ibm.com>
To:	Ingo Molnar <mingo@...e.hu>
CC:	Peter Zijlstra <a.p.zijlstra@...llo.nl>, paul@...lmenage.org,
	rjw@...k.pl, tj@...nel.org, frank.rowand@...sony.com,
	pjt@...gle.com, tglx@...utronix.de, lizf@...fujitsu.com,
	prashanth@...ux.vnet.ibm.com, paulmck@...ux.vnet.ibm.com,
	vatsa@...ux.vnet.ibm.com, linux-kernel@...r.kernel.org,
	linux-pm@...r.kernel.org,
	"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>
Subject: Re: [PATCH 0/4] CPU hotplug, cpusets: Fix CPU online handling related
 to cpusets

Hi Ingo,

On 02/09/2012 01:27 PM, Ingo Molnar wrote:

> 
> * Srivatsa S. Bhat <srivatsa.bhat@...ux.vnet.ibm.com> wrote:
> 
>> IOW, consider:
>>
>> cpuset A has 0-10
>>
>> - Take CPU 10 offline
>>   [We are forced to remove CPU 10 from cpuset A, which becomes 0-9 now]
>>
>>
>>    <Userspace didn't request any change to cpuset A>
>>
>>
>> - Bring back CPU 10 online
>>
>> Now cpuset A is still 0-9! IMO, it should have been 0-10.
> 
> Why is CPU 10 taken out of the cpuset to begin with?
> 
> The cpuset code should be fixed to work with offline CPUs as 
> well - it can obviously not schedule to them, but otherwise it 
> should be fine to have a wider cpuset than the hw can support.
> 


My understanding of the code is that when a CPU is taken offline, it is
removed from all the cpusets and then the scan_for_empty_cpusets() function
is run to move tasks from empty cpusets to their parent cpusets.

And then update_tasks_cpumask() will update the cpus_allowed mask of each
task whose cpus_allowed mask needs an update (because it moved between
cpusets). (This is achieved by setting up cpuset_change_cpumask() as the
callback and calling cgroup_scan_tasks()).

So, from my point of view, cpusets seems to be handling CPU Offline pretty
well, and correctly too. The corresponding CPU online handling is what is
buggy, IMHO, and that is what I intended to fix with this patchset.
 
Regards,
Srivatsa S. Bhat

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